Add updating ui bars and updating console on interaction in EventManager
This commit is contained in:
parent
178115cc4d
commit
b22e69712c
@ -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]:
|
||||
|
Loading…
Reference in New Issue
Block a user