Gold shows up as an int in the HUD now.

This commit is contained in:
Nick Winter 2014-02-26 18:09:09 -08:00
parent 5c1c17c8dd
commit 48122000ed
2 changed files with 1 additions and 2 deletions

View file

@ -113,7 +113,6 @@ module.exports = class LevelBus extends Bus
@changedSessionProperties.teamSpells = true
@session.set({'teamSpells': @teamSpellMap})
@saveSession()
console.log spellTeam, me.team, e.spell.spellKey
if spellTeam is me.team
@onSpellChanged e # Save the new spell to the session, too.

View file

@ -270,7 +270,7 @@ module.exports = class HUDView extends View
if prop is "rotation"
return (val * 180 / Math.PI).toFixed(0) + "˚"
if typeof val is 'number'
if Math.round(val) == val then return val.toFixed(0) # int
if Math.round(val) == val or prop is 'gold' then return val.toFixed(0) # int
if -10 < val < 10 then return val.toFixed(2)
if -100 < val < 100 then return val.toFixed(1)
return val.toFixed(0)