allow quest progress from attack skills BEFORE quest starts

Currently, if you do Brutal Smash or Burst of Flames BEFORE you start a quest, they do NOT damage the quest boss if you start the quest later in the day (this is the opposite of how tasks work). This also means that if you are not on a boss or collection quest, then those skills can't damage the World Boss. I think this is counterintuitive and I think users are expecting those skills to act on Drag'on even when they are not on a quest.

This change causes damage from the skills to be treated just like damage from tasks - it's applied to quests started later that day and to Drag'on.

THIS HAS NOT BEEN TESTED. Sorry. :( I have broken my VM temporarily.
This commit is contained in:
Alice Harris 2014-07-03 16:30:15 +10:00
parent 0c2a9a4b24
commit 964d1a640c

View file

@ -11017,9 +11017,7 @@ api.spells = {
target.value += diminishingReturns(bonus * .02, 4);
bonus *= Math.ceil((target.value < 0 ? 1 : target.value + 1) * .075);
user.stats.exp += diminishingReturns(bonus, 75);
if (user.party.quest.key) {
return user.party.quest.progress.up += diminishingReturns(bonus * .1, 50, 30);
}
return user.party.quest.progress.up += diminishingReturns(bonus * .1, 50, 30);
}
},
mpheal: {
@ -11075,9 +11073,7 @@ api.spells = {
notes: t('spellWarriorSmashNotes'),
cast: function(user, target) {
target.value += 2.5 * (user._statsComputed.str / (user._statsComputed.str + 50)) * user.fns.crit('con');
if (user.party.quest.key) {
return user.party.quest.progress.up += Math.ceil(user._statsComputed.str * .2);
}
return user.party.quest.progress.up += Math.ceil(user._statsComputed.str * .2);
}
},
defensiveStance: {
@ -14220,4 +14216,4 @@ api.wrap = function(user, main) {
}).call(this,require("/Users/lefnire/Dropbox/Sites/habitrpg/modules/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js"))
},{"./content.coffee":5,"./i18n.coffee":6,"/Users/lefnire/Dropbox/Sites/habitrpg/modules/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":2,"lodash":3,"moment":4}]},{},[1])
},{"./content.coffee":5,"./i18n.coffee":6,"/Users/lefnire/Dropbox/Sites/habitrpg/modules/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":2,"lodash":3,"moment":4}]},{},[1])