mirror of
https://github.com/pret/pokemon-reverse-engineering-tools.git
synced 2026-08-09 18:57:29 -05:00
prepare for a wild-based detector
This one isn't implemented yet but might as well get the wrapper functions out of the way.
This commit is contained in:
parent
2ff3478bfd
commit
d6cf3454c4
|
|
@ -64,6 +64,21 @@ class Battle(EmulatorController):
|
|||
"""
|
||||
return self.emulator.is_trainer_switch_prompt()
|
||||
|
||||
def is_wild_switch_prompt(self):
|
||||
"""
|
||||
Detects if the battle is waiting for the player to choose whether or
|
||||
not to continue to fight the wild pokemon.
|
||||
"""
|
||||
return self.emulator.is_wild_switch_prompt()
|
||||
|
||||
def is_switch_prompt(self):
|
||||
"""
|
||||
Detects both trainer and wild switch prompts (for prompting whether to
|
||||
switch pokemon). This is a yes/no box and not the actual pokemon
|
||||
selection menu.
|
||||
"""
|
||||
return self.is_trainer_switch_prompt() or self.is_wild_switch_prompt()
|
||||
|
||||
def is_mandatory_switch(self):
|
||||
"""
|
||||
Detects if the battle is waiting for the player to choose a next
|
||||
|
|
|
|||
|
|
@ -620,6 +620,21 @@ class crystal(object):
|
|||
|
||||
return all([requirement in text for requirement in requirements])
|
||||
|
||||
def is_wild_switch_prompt(self):
|
||||
"""
|
||||
Detects if the battle is waiting for the player to choose whether or
|
||||
not to continue to fight the wild pokemon.
|
||||
"""
|
||||
# TODO: make a better implementation
|
||||
return False
|
||||
|
||||
def is_switch_prompt(self):
|
||||
"""
|
||||
Detects both the trainer-style switch prompt and the wild-style switch
|
||||
prompt. This is the yes/no prompt for whether to switch pokemon.
|
||||
"""
|
||||
return self.is_trainer_switch_prompt() or self.is_wild_switch_prompt()
|
||||
|
||||
def unlock_flypoints(self):
|
||||
"""
|
||||
Unlocks different destinations for flying.
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user