fix(quests): bug fix to multi-drop
This commit is contained in:
+1
-1
@@ -148,7 +148,7 @@ GroupSchema.methods.finishQuest = function(quest, cb) {
|
||||
case 'eggs':
|
||||
case 'food':
|
||||
case 'hatchingPotions':
|
||||
updates['$inc']['items.'+quest.drop.type+'.'+dropK] = 1;
|
||||
updates['$inc']['items.'+item.type+'.'+dropK] = _.where(quest.drop.items,{type:item.type,key:item.key}).length;
|
||||
break;
|
||||
case 'pets':
|
||||
updates['$set']['items.pets.'+dropK] = 5;
|
||||
|
||||
Reference in New Issue
Block a user