diff --git a/script/content.coffee b/script/content.coffee index 70976dabd2..bf27a66736 100644 --- a/script/content.coffee +++ b/script/content.coffee @@ -10,11 +10,12 @@ moment = require 'moment' ### classes = ['warrior', 'rogue', 'healer', 'wizard'] -gearTypes = ['armor', 'weapon', 'shield', 'head', 'back'] +gearTypes = ['armor', 'weapon', 'shield', 'head', 'back', 'headAccessory'] events = winter: {start:'2013-12-31',end:'2014-02-01'} birthday: {start:'2013-01-30',end:'2014-02-01'} + spring: {start:'2014-03-21',end:'2014-05-01'} mystery = 201402: {start:'2014-02-22',end:'2014-02-28'} diff --git a/script/index.coffee b/script/index.coffee index 2b7c8cfec6..637617f52d 100644 --- a/script/index.coffee +++ b/script/index.coffee @@ -122,7 +122,7 @@ preenHistory = (history) -> api.updateStore = (user) -> return unless user changes = [] - _.each ['weapon', 'armor', 'shield', 'head', 'back'], (type) -> + _.each ['weapon', 'armor', 'shield', 'head', 'back', 'headAccessory'], (type) -> found = _.find content.gear.tree[type][user.stats.class], (item) -> !user.items.gear.owned[item.key] changes.push(found) if found @@ -139,8 +139,9 @@ api.updateStore = (user) -> when 'head' then 3 when 'shield' then 4 when 'back' then 5 - when 'potion' then 6 - else 7 + when 'headAccessory' then 6 + when 'potion' then 7 + else 8 ### ------------------------------------------------------ @@ -1291,7 +1292,8 @@ api.wrap = (user, main=true) -> lastGearClassTypeMatrix = {} _.each content.classes, (klass) -> lastGearClassTypeMatrix[klass] = {} - _.each content.gearTypes, (type) -> + #_.each content.gearTypes, (type) -> + _.each ['armor', 'weapon', 'shield', 'head'], (type) -> lastGearClassTypeMatrix[klass][type] = false return true # false exits the each loop early