Ntoes and HUD

This commit is contained in:
Ruben Müller 2014-12-07 17:41:21 +01:00
parent 9a6ef0c994
commit de01da9f81
6 changed files with 7 additions and 11 deletions

View file

@ -11,19 +11,10 @@ Title: Entire game on one screen
* TODO HUD
** hud: energie progress bar :aaron:
** hud: resources "release to space" on click :aaron:
** Hint für shortcuts anzeigen :ruben:
** Preise für entities :ruben:
* TODO Entities
** solarpanel item :aaron:
* TODO Polishing
* TODO OUTRO
** animation bei voller energybar: typ fliegt davon
** win screen
* TODO EXTRA Polishing
** game balancing
** Miner verschieben
** Silos: Farben je nach Kapazität einfärben
** win screen

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

View file

@ -80,6 +80,8 @@ app.game =
@currentSelectedTile.entity = new Miner
else
@speechbubble.say 'nores'
else
@speechbubble.say 'nosel'
createSilo: ->
if @currentSelectedTile
@ -90,6 +92,8 @@ app.game =
@speechbubble.say 'nores'
else
@speechbubble.say 'toofar'
else
@speechbubble.say 'nosel'
checkResource: (type, amount, drain = false) ->
if @resources[type] >= amount

View file

@ -62,7 +62,7 @@ app.game.hud =
showBuildInfo: ->
clearTimeout(@timeout) if @timeout
@buildinfo = true
@timeout = window.setTimeout @hideBuildInfo, 2000
@timeout = window.setTimeout @hideBuildInfo, 4000
hideBuildInfo: ->
app.game.hud.buildinfo = false

View file

@ -9,6 +9,7 @@ app.game.speechbubble =
when 'help' then @sprite = [0, 0, 27, 13]
when 'toofar' then @sprite = [0, 13, 90, 13]
when 'nores' then @sprite = [0, 26, 90, 13]
when 'nosel' then @sprite = [0, 39, 90, 13]
@visible = true
@timeout = window.setTimeout @hide, 1000