diff --git a/pokemonred_puffer/environment.py b/pokemonred_puffer/environment.py index 20617e7..09b47cd 100644 --- a/pokemonred_puffer/environment.py +++ b/pokemonred_puffer/environment.py @@ -884,6 +884,9 @@ def step(self, action): if self.save_video and self.step_count == 0: self.start_video() + if self.disable_wild_encounters: + self.pyboy.memory[self.pyboy.symbol_lookup("wRepelRemainingSteps")[1]] = 100 + _, wMapPalOffset = self.pyboy.symbol_lookup("wMapPalOffset") if self.auto_flash and self.pyboy.memory[wMapPalOffset] == 6: self.pyboy.memory[wMapPalOffset] = 0