diff --git a/columbus/env.py b/columbus/env.py index 3a659e7..b87863e 100644 --- a/columbus/env.py +++ b/columbus/env.py @@ -277,8 +277,13 @@ class ColumbusEnv(gym.Env): self.setup() self.entities.append(self.agent) # add it last, will be drawn on top self.observable.reset() + self._reset_paths() return self.observable.get_observation() + def _reset_paths(self): + self.path_overlay = pygame.Surface( + (self.width, self.height), pygame.SRCALPHA, 32) + def _draw_entities(self): for entity in self.entities: entity.draw()