fixed eat detection after death

This commit is contained in:
lars 2025-08-13 10:21:16 +02:00
parent 50c755e277
commit e71d1ebd70

View File

@ -383,6 +383,9 @@ class FlowerGameEnv(gym.Env):
if found_blue: if found_blue:
print("In Bombe gelaufen!") print("In Bombe gelaufen!")
reward -= self.collision_penalty reward -= self.collision_penalty
self._cooldown = self.contact_cooldown_frames
self.prev_flower_x = None
self.prev_flower_y = None
time.sleep(0.5) time.sleep(0.5)
pyautogui.hotkey("ctrl", "p") pyautogui.hotkey("ctrl", "p")
time.sleep(0.5) time.sleep(0.5)