check armor/weapon on userObj (shouldnt have to?)

This commit is contained in:
Tyler Renelle 2013-01-18 21:42:43 -05:00
parent 25227abce9
commit dce251a767

View file

@ -38,8 +38,8 @@ get '/', (page, model, next) ->
# Setup Item Store
_view.items =
armor: content.items.armor[parseInt(userObj.items.armor) + 1]
weapon: content.items.weapon[parseInt(userObj.items.weapon) + 1]
armor: content.items.armor[parseInt(userObj.items?.armor || 0) + 1]
weapon: content.items.weapon[parseInt(userObj.items?.weapon || 0) + 1]
potion: content.items.potion
reroll: content.items.reroll