From b22e69712cceaa877d8e4592af512a8859792b7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Czeka=C5=84ski?= Date: Mon, 6 Apr 2020 13:20:28 +0200 Subject: [PATCH] Add updating ui bars and updating console on interaction in EventManager --- src/game/EventManager.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/game/EventManager.py b/src/game/EventManager.py index 508dc06..66e8023 100644 --- a/src/game/EventManager.py +++ b/src/game/EventManager.py @@ -35,6 +35,8 @@ class EventManager: self.handlePlayerControls(keys) self.keyTimeout = 0 + self.game.screen.ui.updateBarsBasedOnPlayerStats(self.player.statistics) + def handlePlayerControls(self, keys): # Key names are temporary # TODO: Load key bindings from JSON @@ -50,6 +52,7 @@ class EventManager: self.game.map.removeSpriteFromMap(object) elif type(object) is Interactable: object.on_interaction(self.player) + self.game.screen.ui.updateOnPlayerInteraction(self.player.statistics, object) # Movement if keys[pygame.K_w]: