From 835179cb0f1ab0db38ab42c56ccbf38060284d2a Mon Sep 17 00:00:00 2001 From: thatguy11325 <148832074+thatguy11325@users.noreply.github.com> Date: Tue, 23 Jul 2024 17:28:14 -0400 Subject: [PATCH] calc party in reset --- pokemonred_puffer/environment.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pokemonred_puffer/environment.py b/pokemonred_puffer/environment.py index 1a72044..1aba2a8 100644 --- a/pokemonred_puffer/environment.py +++ b/pokemonred_puffer/environment.py @@ -334,6 +334,7 @@ def reset(self, seed: Optional[int] = None, options: Optional[dict[str, Any]] = self.party = PartyMons(self.pyboy) self.update_pokedex() self.update_tm_hm_moves_obtained() + self.party_size = self.read_m("wPartyCount") self.taught_cut = self.check_if_party_has_hm(0xF) self.levels_satisfied = False self.base_explore = 0 @@ -345,7 +346,6 @@ def reset(self, seed: Optional[int] = None, options: Optional[dict[str, Any]] = self.last_health = 1 self.total_heal_health = 0 self.died_count = 0 - self.party_size = 0 self.step_count = 0 self.blackout_check = 0 self.blackout_count = 0