Added class GameStats, added Pokédex records for eggs seen and expanded seen_forms to include shinies

This commit is contained in:
Maruno17
2021-11-13 23:13:28 +00:00
parent 12fd500dbc
commit c6ecf60172
39 changed files with 443 additions and 42 deletions

View File

@@ -1,11 +1,13 @@
class SafariState
attr_accessor :ballcount
attr_accessor :captures
attr_accessor :decision
attr_accessor :steps
def initialize
@start = nil
@ballcount = 0
@captures = 0
@inProgress = false
@steps = 0
@decision = 0
@@ -43,6 +45,7 @@ class SafariState
def pbEnd
@start = nil
@ballcount = 0
@captures = 0
@inProgress = false
@steps = 0
@decision = 0
@@ -130,6 +133,11 @@ def pbSafariBattle(species,level)
# 2 - Player ran out of Safari Balls
# 3 - Player or wild Pokémon ran from battle, or player forfeited the match
# 4 - Wild Pokémon was caught
if decision == 4
$stats.safari_pokemon_caught += 1
pbSafariState.captures += 1
$stats.most_captures_per_safari_game = [$stats.most_captures_per_safari_game, pbSafariState.captures].max
end
pbSet(1,decision)
# Used by the Poké Radar to update/break the chain
Events.onWildBattleEnd.trigger(nil,species,level,decision)

View File

@@ -188,6 +188,7 @@ class BugContestState
$player.party=[chosenpkmn]
@decision=0
@ended=false
$stats.bug_contest_count += 1
end
def place
@@ -210,6 +211,7 @@ class BugContestState
else
@ended=false
end
$stats.bug_contest_wins += 1 if place == 0
@lastPokemon=nil
@otherparty=[]
@reception=[]