Advertisement
TechSkylander1518

Contingency PokeGear

Apr 19th, 2021 (edited)
266
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 1.33 KB | None | 0 0
  1.   def pbStartScreen
  2.     commands = []
  3.     cmdDex     = -1
  4.     cmdMap     = -1
  5.     cmdCase     = -1
  6.     cmdPhone   = -1
  7.     cmdJukebox = -1
  8.     commands[cmdDex = commands.length]     = ["dex",_INTL("PokéDex")]
  9.     commands[cmdMap = commands.length]     = ["map",_INTL("Map")]
  10.     commands[cmdCase = commands.length]     = ["case",_INTL("TM Case")]
  11.     if $PokemonGlobal.phoneNumbers && $PokemonGlobal.phoneNumbers.length>0
  12.       commands[cmdPhone = commands.length] = ["phone",_INTL("Phone")]
  13.     end
  14.     commands[cmdJukebox = commands.length] = ["jukebox",_INTL("Jukebox")]
  15.     @scene.pbStartScene(commands)
  16.     loop do
  17.       cmd = @scene.pbScene
  18.       if cmd<0
  19.         break
  20.       elsif cmdDex>=0 && cmd==cmdDex
  21.         scene = PokemonPokedex_Scene.new
  22.         screen = PokemonPokedexScreen.new(scene)
  23.         screen.pbStartScreen
  24.       elsif cmdMap>=0 && cmd==cmdMap
  25.         pbShowMap(-1,false)
  26.       elsif cmdCase>=0 && cmd==cmdCase
  27.         TMCase.new
  28.       elsif cmdPhone>=0 && cmd==cmdPhone
  29.         pbFadeOutIn {
  30.           PokemonPhoneScene.new.start
  31.         }
  32.       elsif cmdJukebox>=0 && cmd==cmdJukebox
  33.         pbFadeOutIn {
  34.           scene = PokemonJukebox_Scene.new
  35.           screen = PokemonJukeboxScreen.new(scene)
  36.           screen.pbStartScreen
  37.         }
  38.       end
  39.     end
  40.     @scene.pbEndScene
  41.   end
  42. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement