HUD update

This commit is contained in:
Ruben Müller 2014-12-07 17:08:31 +01:00
parent 8e3d344255
commit 78c245d3e1

View file

@ -43,11 +43,16 @@ app.game.hud =
app.layer.setPixel(resourcePanelColor, x, y) app.layer.setPixel(resourcePanelColor, x, y)
switch panelusage switch panelusage
when 'tile'
@showResources()
when 'entity' when 'entity'
#app.layer.drawRegion app.images.entities, currentSelectedTile.entity.sprite(), 44, 102 #app.layer.drawRegion app.images.entities, currentSelectedTile.entity.sprite(), 44, 102
if currentSelectedTile.entity.isMoveable() if currentSelectedTile.entity.isMoveable()
app.layer.drawRegion @itemArrow.image, @itemArrow.sprite(), 44, 102 app.layer.drawRegion @itemArrow.image, @itemArrow.sprite(), 44, 102
when 'resources' when 'resources'
@showResources()
showResources: ->
# resources # resources
i = 0 i = 0
for type, amount of app.game.resources for type, amount of app.game.resources