Skip to content

Commit

Permalink
solve strength puzzles config
Browse files Browse the repository at this point in the history
  • Loading branch information
thatguy11325 committed Jun 15, 2024
1 parent 2873489 commit cb934fc
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -57,6 +57,7 @@ env:
auto_use_surf: True
auto_teach_surf: True
auto_teach_strength: True
auto_solve_strength_puzzles: True
auto_remove_all_nonuseful_items: True
auto_pokeflute: True
infinite_money: True
6 changes: 4 additions & 2 deletions pokemonred_puffer/environment.py
Original file line number Diff line number Diff line change
@@ -98,6 +98,7 @@ def __init__(self, env_config: pufferlib.namespace):
self.auto_teach_strength = env_config.auto_teach_strength
self.auto_use_cut = env_config.auto_use_cut
self.auto_use_surf = env_config.auto_use_surf
self.auto_solve_strength_puzzles = env_config.auto_solve_strength_puzzles
self.auto_remove_all_nonuseful_items = env_config.auto_remove_all_nonuseful_items
self.auto_pokeflute = env_config.auto_pokeflute
self.infinite_money = env_config.infinite_money
@@ -585,8 +586,9 @@ def run_action_on_emulator(self, action):
if self.read_bit(0xD857, 0):
if self.auto_teach_strength and not self.check_if_party_has_hm(0x46):
self.teach_hm(0x46, 15, STRENGTH_SPECIES_IDS)
self.solve_missable_strength_puzzle()
self.solve_switch_strength_puzzle()
if self.auto_solve_strength_puzzles:
self.solve_missable_strength_puzzle()
self.solve_switch_strength_puzzle()

if self.read_bit(0xD76C, 0) and self.auto_pokeflute:
self.use_pokeflute()

0 comments on commit cb934fc

Please sign in to comment.