Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module Menu_Settings
- QUESTLOG = "Questbuch" # Bezeichnung für das Questlog
- ALBUM = "Album" # Bezeichnung für das Album
- ERFOLGE = "Erfolge" # Bezeichnung für Erfolge
- PUNKTE = "Attribute"
- SKILLTREE = "Skilltree"
- ENZYKLOPÄDIE = "Enzklopädie"
- ARTEFAKTE = "Artefakte"
- TAGEBUCH = "Tagebuch"
- SWITCHES = {
- # Menupunkt ID => Switch ID
- 1 => 5,
- 2 => 6,
- }
- end
- class Scene_Menu
- #--------------------------------------------------------------------------
- # * Create Command Window
- #--------------------------------------------------------------------------
- def create_command_window
- s1 = Vocab::item
- s2 = Vocab::skill
- s3 = Vocab::equip
- s4 = Vocab::status
- s5 = Menu_Settings::QUESTLOG
- s6 = Menu_Settings::ALBUM
- s7 = Menu_Settings::ERFOLGE
- s8 = Menu_Settings::PUNKTE
- s9 = Menu_Settings:: SKILLTREE
- s10 = Menu_Settings:: ENZYKLOPÄDIE
- s11 = Menu_Settings:: ARTEFAKTE
- s12 = Menu_Settings:: TAGEBUCH
- s13 = Vocab::game_end
- @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, s13])
- @command_window.index = @menu_index
- if $game_party.members.size == 0 # If number of party members is 0
- @command_window.draw_item(0, false) # Disable item
- @command_window.draw_item(1, false) # Disable skill
- @command_window.draw_item(2, false) # Disable equipment
- @command_window.draw_item(3, false) # Disable status
- end
- for key in Menu_Settings::SWITCHES.keys
- @command_window.draw_item(key,false) if !$game_switches[Menu_Settings::SWITCHES[key]]
- end
- end
- #--------------------------------------------------------------------------
- # * Update Command Selection
- #--------------------------------------------------------------------------
- def update_command_selection
- if Input.trigger?(Input::B)
- Sound.play_cancel
- $scene = Scene_Map.new
- elsif Input.trigger?(Input::C)
- if $game_party.members.size == 0 and @command_window.index < 4
- Sound.play_buzzer
- return
- end
- if Menu_Settings::SWITCHES.keys.include?(@command_window.index) && !$game_switches[Menu_Settings::SWITCHES[@command_window.index]]
- Sound.play_buzzer
- return
- end
- Sound.play_decision
- case @command_window.index
- when 0 # Item
- $scene = Scene_Item.new
- when 1,2,3,7,8 # Skill, equipment, status
- start_actor_selection
- when 12 # End Game
- $scene = Scene_End.new
- when 4
- $scene = Scene_Questlog.new
- when 5
- $scene = Scene_VampyrBestiary.new
- when 6
- $scene = Scene_Erfolge.new
- when 9
- $scene = Scene_Custom_List.new
- when 10
- $scene = Collection_Screen.new
- when 11
- $scene = Scene_Diary.new
- end
- end
- end
- def update_actor_selection
- if Input.trigger?(Input::B)
- Sound.play_cancel
- end_actor_selection
- elsif Input.trigger?(Input::C)
- $game_party.last_actor_index = @status_window.index
- Sound.play_decision
- case @command_window.index
- when 1 # skill
- $scene = Scene_Skill.new(@status_window.index)
- when 2 # equipment
- $scene = Scene_Equip.new(@status_window.index)
- when 3 # status
- $scene = Scene_Status.new(@status_window.index)
- when 7
- $scene = Scene_Stat_Dist.new(@status_window.index)
- when 8
- $scene = Scene_SkillTree.new(@status_window.index)
- end
- end
- end
- end
- class Scene_Item
- def return_scene
- $scene = Scene_Menu.new(0)
- end
- end
- class Scene_Skill
- def return_scene
- $scene = Scene_Menu.new(1)
- end
- end
- class Scene_Equip
- def return_scene
- $scene = Scene_Menu.new(2)
- end
- end
- class Scene_Status
- def return_scene
- $scene = Scene_Menu.new(3)
- end
- end
- class Scene_Questlog
- def return_scene
- if @from_menu
- $scene = Scene_Menu.new(Questlog::MENU_INDEX)
- else
- $scene = Scene_Map.new
- end
- end
- end
- class Scene_End
- def return_scene
- $scene = Scene_Menu.new(12)
- end
- end
- class Scene_VampyrBestiary
- def return_scene
- $scene = Scene_Menu.new(5)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement