# Pokedex
@@openPokedex = Proc.new{
if DEXDEPENDSONLOCATION
pbFadeOutIn(99999){
scene = PokemonPokedex_Scene.new
screen = PokemonPokedexScreen.new(scene)
screen.pbStartScreen
}
else
if $PokemonGlobal.pokedexViable.length==1
$PokemonGlobal.pokedexDex = $PokemonGlobal.pokedexViable[0]
$PokemonGlobal.pokedexDex = -1 if $PokemonGlobal.pokedexDex==$PokemonGlobal.pokedexUnlocked.length-1
pbFadeOutIn(99999){
scene = PokemonPokedex_Scene.new
screen = PokemonPokedexScreen.new(scene)
screen.pbStartScreen
}
else
pbFadeOutIn(99999){
scene = PokemonPokedexMenu_Scene.new
screen = PokemonPokedexMenuScreen.new(scene)
screen.pbStartScreen
}
end
end
}