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.

How to add Command in Menu

Status
Not open for further replies.
If someone could help me, I would really appreciate it. Since baniff_script_ability = 0 I was wondering how to add new commands to the main menu. Here's a visual aid (ooooh)


Item
Skill
Equip
{New Command}
{New Command}
Save
End

I'm using the default menu system, and I just need the add two new commands. When you push the command, it goes to a scene... you know. To make room, go ahead and revome the Game Time. THIS IS NOT A CMS!!! (So it should be really easy for any scripter) Thank you so much!
 

poccil

Sponsor

Here are the changes to make in the script section Scene_Menu:

From lines 19 through 27:

Code:
    # Make command window
    @command_window = Window_Command.new(160,[
     $data_system.words.item,
     $data_system.words.skill,
     $data_system.words.equip,
     "[New Command]",
     "[New Command]",
     "Status",
     "Save",
     "End Game"
    ])
    @command_window.index = @menu_index

Making playtime window hidden (near line 41):

Code:
    @playtime_window = Window_PlayTime.new
    @playtime_window.x = 0
    @playtime_window.y = 224
    @playtime_window.visible = false

Changing indices of commands (from line 143, some lines were removed
to save space):
Code:
      when 3  # new command 1
        $game_system.se_play($data_system.decision_se)
        $scene=Scene_NewCommand1.new # just an example
      when 4  # new command 2
        $game_system.se_play($data_system.decision_se)
        $scene=Scene_NewCommand2.new # just an example
      when 5  # status
         # [Code left out]
      when 6  # save
         # [Code left out]
      when 7  # end game
         # [Code left out]
 

arev

Sponsor

This topic has been resolved. If baniff or any other users have any questions or further problems regarding this topic, please create a new thread about them.

Thank you!
 
Status
Not open for further replies.

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