diff --git a/lib/game/api/game.js b/lib/game/api/game.js index 257ac40..f73c648 100644 --- a/lib/game/api/game.js +++ b/lib/game/api/game.js @@ -395,7 +395,7 @@ router.post('/place-spawn', auth.tokenAuth, jsonResponse((request) => { }))) : q.when()) .then(() => db['rooms.objects'].removeWhere({$and: [{room: request.body.room}, {user: {$ne: null}}, {type: {$in: _.keys(C.CONSTRUCTION_COST)}}]})) .then(() => db['rooms.objects'].update({$and: [{room: request.body.room}, {type: 'controller'}, {level: 0}]}, - {$set: {user: ""+request.user._id, level: 1, progress: 0, downgradeTime: null, safeMode: gameTime + 20000}})) + {$set: {user: ""+request.user._id, level: 1, progress: 0, downgradeTime: null, safeMode: gameTime + C.SAFE_MODE_DURATION }})) .then(() => db['rooms.objects'].update({$and: [{room: request.body.room}, {type: 'source'}]}, {$set: {invaderHarvested: 0}})) .then(() => db['rooms.objects'].insert(objectsToInsert))