Code tidying with Rubocop

This commit is contained in:
Maruno17
2023-07-18 22:42:10 +01:00
parent 6053363715
commit a5734eaf46
68 changed files with 276 additions and 232 deletions

View File

@@ -67,7 +67,8 @@ class PokemonPokedexInfo_Scene
pbFadeInAndShow(@sprites) { pbUpdate }
end
def pbStartSceneBrief(species) # For standalone access, shows first page only
# For standalone access, shows first page only.
def pbStartSceneBrief(species)
@viewport = Viewport.new(0, 0, Graphics.width, Graphics.height)
@viewport.z = 99999
dexnum = 0
@@ -165,7 +166,7 @@ class PokemonPokedexInfo_Scene
next if !$player.pokedex.seen_form?(@species, real_gender, sp.form) && !Settings::DEX_SHOWS_ALL_FORMS
real_gender = 2 if sp.gender_ratio == :Genderless
ret.push([sp.form_name, real_gender, sp.form])
elsif sp.form == 0 && # Form 0 and no gender differences
elsif sp.form == 0 && !gender_differences
2.times do |real_gndr|
next if !$player.pokedex.seen_form?(@species, real_gndr, sp.form) && !Settings::DEX_SHOWS_ALL_FORMS
ret.push([sp.form_name || _INTL("One Form"), 0, sp.form])
@@ -587,7 +588,8 @@ class PokemonPokedexInfoScreen
return ret # Index of last species viewed in dexlist
end
def pbStartSceneSingle(species) # For use from a Pokémon's summary screen
# For use from a Pokémon's summary screen.
def pbStartSceneSingle(species)
region = -1
if Settings::USE_CURRENT_REGION_DEX
region = pbGetCurrentRegion
@@ -610,7 +612,8 @@ class PokemonPokedexInfoScreen
@scene.pbEndScene
end
def pbDexEntry(species) # For use when capturing a new species
# For use when capturing or otherwise obtaining a new species.
def pbDexEntry(species)
@scene.pbStartSceneBrief(species)
@scene.pbSceneBrief
@scene.pbEndScene