Moved all settings into module Settings

This commit is contained in:
Maruno17
2021-02-01 21:03:58 +00:00
parent 923844fdc7
commit 1209b804e9
88 changed files with 848 additions and 839 deletions

View File

@@ -77,7 +77,7 @@ class Trainer
end
def party_full?
return party_count >= MAX_PARTY_SIZE
return party_count >= Settings::MAX_PARTY_SIZE
end
# Returns true if there are no usable Pokémon in the player's party.
@@ -211,7 +211,7 @@ class PlayerTrainer < Trainer
end
def money=(value)
@money = value.clamp(0, MAX_MONEY)
@money = value.clamp(0, Settings::MAX_MONEY)
end
def badge_count
@@ -301,7 +301,7 @@ class PlayerTrainer < Trainer
@character_ID = nil
@outfit = 0
@badges = [false] * 8
@money = INITIAL_MONEY
@money = Settings::INITIAL_MONEY
clear_pokedex
@pokegear = false
@pokedex = false

View File

@@ -19,7 +19,7 @@ end
def pbNewTrainer(tr_type, tr_name, tr_version, save_changes = true)
party = []
for i in 0...MAX_PARTY_SIZE
for i in 0...Settings::MAX_PARTY_SIZE
if i == 0
pbMessage(_INTL("Please enter the first Pokémon.",i))
else