Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Attempted myself, and failed misserbly. -Game Mode Selection.-

Taylor

Sponsor

I tried doing this myself, but Seph's Triple Triad has an error whenever I edit Scene_Title, or don't pass through it when starting the project.

GAHHHHHH THIS SCRIPT IS DRIVING UP THE F***ING WALL >_<

I'm trying to create a new Title screen, by making the game go to a map for an intro, caused by an altered Scene_Title.
Code:
#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  This class performs title screen processing.
#==============================================================================

class Scene_Title
  #--------------------------------------------------------------------------
  # * Main Processing
  #--------------------------------------------------------------------------
  def main
    return if main_battle_test?
    # Load database
    $data_actors        = load_data("Data/Actors.rxdata")
    $data_classes       = load_data("Data/Classes.rxdata")
    $data_skills        = load_data("Data/Skills.rxdata")
    $data_items         = load_data("Data/Items.rxdata")
    $data_weapons       = load_data("Data/Weapons.rxdata")
    $data_armors        = load_data("Data/Armors.rxdata")
    $data_enemies       = load_data("Data/Enemies.rxdata")
    $data_troops        = load_data("Data/Troops.rxdata")
    $data_states        = load_data("Data/States.rxdata")
    $data_animations    = load_data("Data/Animations.rxdata")
    $data_tilesets      = load_data("Data/Tilesets.rxdata")
    $data_common_events = load_data("Data/CommonEvents.rxdata")
    $data_system        = load_data("Data/System.rxdata")
    # Make system object
    $game_system = Game_System.new
    main_background
    main_menu
    main_test_continue
    main_audio
    # Execute transition
    Graphics.transition
    # Make each type of game object
    $game_temp          = Game_Temp.new
    $game_system        = Game_System.new
    $game_switches      = Game_Switches.new
    $game_variables     = Game_Variables.new
    $game_self_switches = Game_SelfSwitches.new
    $game_screen        = Game_Screen.new
    $game_actors        = Game_Actors.new
    $game_party         = Game_Party.new
    $game_troop         = Game_Troop.new
    $game_map           = Game_Map.new
    $game_player        = Game_Player.new
    # Set up initial map position
    $game_map.setup(04)
    # Move player to initial position
    $game_player.moveto(0, 0)
    # Refresh player
    $game_player.refresh
    # Run automatic change for BGM and BGS set with map
    $game_map.autoplay
    # Update map (run parallel process event)
    $game_map.update
    # Switch to map screen
    $scene = Scene_Map.new
  end
  #--------------------------------------------------------------------------
  # * Battle Test Check
  #--------------------------------------------------------------------------
  def main_battle_test?
    # If battle test
    if $BTEST
      battle_test
      return true
    end
    return false
  end
  #--------------------------------------------------------------------------
  # * Load Database
  #--------------------------------------------------------------------------
  def main_database
  end
  #--------------------------------------------------------------------------
  # * Background Initialization
  #--------------------------------------------------------------------------
  def main_background
  end
  #--------------------------------------------------------------------------
  # * Main Menu Initialization
  #--------------------------------------------------------------------------
  def main_menu
  end
  #--------------------------------------------------------------------------
  # * Main Test Initialization
  #--------------------------------------------------------------------------
  def main_test_continue
  end
  #--------------------------------------------------------------------------
  # * Main Audio Initialization
  #--------------------------------------------------------------------------
  def main_audio
  end
  #--------------------------------------------------------------------------
  # * Main Loop
  #--------------------------------------------------------------------------
  def main_loop
  end
  #--------------------------------------------------------------------------
  # * Main Scene Scene Change
  #--------------------------------------------------------------------------
  def main_scenechange?
    # Abort loop if screen is changed
    if $scene != self
      return true
    end
    return false
  end
  #--------------------------------------------------------------------------
  # * Main Dispose
  #--------------------------------------------------------------------------
  def main_dispose
    automatic_dispose
  end
end
This takes the player to Map ID004 fine, where an autostart takes place then the script "$scene = Scene_FileSelect.new" takes place.
This'll be an edit of the original Scene_Title to have four options, depending on the story you want to play. The fourth being "Load Game". Instead of text I want to use images.

Here is my Scene_FileSelect anyway, it's just the same as Scene_Title for now.
Code:
#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  This class performs title screen processing.
#==============================================================================

class Scene_FileSelect < Scene_Title
  #--------------------------------------------------------------------------
  # * Main Processing
  #--------------------------------------------------------------------------
  def main
    return if main_battle_test?
    main_background
    main_menu
    main_test_continue
    main_audio
    # Execute transition
    Graphics.transition
    # Main loop
    loop do
      main_loop
      break if main_scenechange?
    end
    # Prepare for transition
    Graphics.freeze
    main_dispose
  end
  #--------------------------------------------------------------------------
  # * Battle Test Check
  #--------------------------------------------------------------------------
  def main_battle_test?
    # If battle test
    if $BTEST
      battle_test
      return true
    end
    return false
  end
  #--------------------------------------------------------------------------
  # * Load Database
  #--------------------------------------------------------------------------
  def main_database
  end
  #--------------------------------------------------------------------------
  # * Background Initialization
  #--------------------------------------------------------------------------
  def main_background
    # Make title graphic
    @sprite = Sprite.new
    @sprite.bitmap = RPG::Cache.title($data_system.title_name)
  end
  #--------------------------------------------------------------------------
  # * Main Menu Initialization
  #--------------------------------------------------------------------------
  def main_menu
    # Make command window
    s1 = "New Game"
    s2 = "Continue"
    s3 = "Shutdown"
    @command_window = Window_Command.new(192, [s1, s2, s3])
    @command_window.back_opacity = 160
    @command_window.x = 320 - @command_window.width / 2
    @command_window.y = 288
  end
  #--------------------------------------------------------------------------
  # * Main Test Initialization
  #--------------------------------------------------------------------------
  def main_test_continue
    # Continue enabled determinant
    # Check if at least one save file exists
    # If enabled, make @continue_enabled true; if disabled, make it false
    @continue_enabled = false
    for i in 0..3
      if FileTest.exist?("Save#{i+1}.rxdata")
        @continue_enabled = true
      end
    end
    # If continue is enabled, move cursor to "Continue"
    # If disabled, display "Continue" text in gray
    if @continue_enabled
      @command_window.index = 1
    else
      @command_window.disable_item(1)
    end
  end
  #--------------------------------------------------------------------------
  # * Main Audio Initialization
  #--------------------------------------------------------------------------
  def main_audio
    # Play title BGM
    $game_system.bgm_play($data_system.title_bgm)
    # Stop playing ME and BGS
    Audio.me_stop
    Audio.bgs_stop
  end
  #--------------------------------------------------------------------------
  # * Main Loop
  #--------------------------------------------------------------------------
  def main_loop
    # Update game screen
    Graphics.update
    # Update input information
    Input.update
    # Frame update
    update
  end
  #--------------------------------------------------------------------------
  # * Main Scene Scene Change
  #--------------------------------------------------------------------------
  def main_scenechange?
    # Abort loop if screen is changed
    if $scene != self
      return true
    end
    return false
  end
  #--------------------------------------------------------------------------
  # * Main Dispose
  #--------------------------------------------------------------------------
  def main_dispose
    automatic_dispose
  end
end
But I can't even get this far! i_i I keep getting errors in the TT scripts.
If I load a game and try anything TT related, I get an error In Triple Triad 1 at line 375.
If I start a new game, I get the same error as soon as I press enter on "New Game".

I don't whether this should be in support or requests...

When I get past this big problem, I may request more edits to this script later.

EDIT: Whooops. completly forgot to mention that those scripts are edits of the SDK Scene_Title. I thought that If I edited it and not the original Scene_Title, it'd work. But no.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top