Protected
gamePrimarily for double battles, keeps track of last enemy and player pokemon that triggered its ability or used a move
Optional
mysteryIf the current battle is a Mystery Encounter, this will always be defined
Optional
mysteryReturns if the battle is of type BattleType.MYSTERY_ENCOUNTER
Generates a random number using the current battle's seed. Calls Utils.randSeedInt
How large of a range of random numbers to choose from. If range <= 1, returns min
The minimum integer to pick, default 0
A random integer between min and (min + range - 1)
Saves the number of times a Pokemon on the enemy's side has fainted during this battle. This is saved here since we encounter a new enemy every wave.
globalScene.arena.playerFaints
is the corresponding faint counter for the player and needs to be save across waves (reset every arena encounter).