habitica-self-host/website/common/script/ops
Alyssa Batula 016447ec77 Critical Hits now affect boss damage fixes #5429 (#8092)
* Moved critical hit calculation from _addPoints() to _calculateDelta(). Added user as an input argument to _calculateDelta() so for critical hit calculation

* Changed test to expect task value of 1.5 after critical hit

* Revert "Moved critical hit calculation from _addPoints() to _calculateDelta(). Added user as an input argument to _calculateDelta() so for critical hit calculation"

This reverts commit 51b8ab6498d989d1f9494ac43c2605f3d4d14a35.

* Moved critical hit calculation to _changeTaskValue(). Use value stored in user._tmp.crit in _addPoints()

* Test is no longer affected by critical hits

* Removed unneeded comment

* Added WIP test of critical hits

* Want the crit function to return 2 to test critical hits

* Changed crit function to export as a function within an object so that it can be stubbed for testing. References to the crit() function were updated to call crit.crit() instead

* Added test for increased experience on critical hits
2017-01-18 08:11:39 -07:00
..
addTag.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
addTask.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
allocate.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
allocateNow.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
blockUser.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
buy.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
buyArmoire.js Re-enable armoire tests 2016-10-20 22:04:24 -05:00
buyGear.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
buyHealthPotion.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
buyMysterySet.js Preventing users from buying already gifted subscriber items (#7734) 2016-12-15 10:00:49 -06:00
buyQuest.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
buySpecialSpell.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
changeClass.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
clearPMs.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
deletePM.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
deleteTag.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
deleteTask.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
disableClasses.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
equip.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
feed.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
hatch.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
hourglassPurchase.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
index.js Webhook improvements (#7879) 2016-10-02 09:16:22 -05:00
markPMSRead.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
openMysteryItem.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
purchase.js Fixes #8227 (#8380) 2017-01-10 12:00:53 -07:00
readCard.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
rebirth.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
releaseBoth.js Only unequip Gen 1 pets/mounts when releasing pets/mounts, fixes #5366 (#8119) 2016-10-20 22:00:15 -05:00
releaseMounts.js Only unequip Gen 1 pets/mounts when releasing pets/mounts, fixes #5366 (#8119) 2016-10-20 22:00:15 -05:00
releasePets.js Only unequip Gen 1 pets/mounts when releasing pets/mounts, fixes #5366 (#8119) 2016-10-20 22:00:15 -05:00
reroll.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
reset.js Ensured group tasks are removed from places that challegnes tasks are (#8359) 2017-01-07 12:01:12 +01:00
revive.js fix(api,client): Pass in predictable random to revive randomVal calls 2016-09-30 08:39:30 -05:00
scoreTask.js Critical Hits now affect boss damage fixes #5429 (#8092) 2017-01-18 08:11:39 -07:00
sell.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
sleep.js Remove unused v2 code from /website/common/script (#8034) 2016-09-22 21:23:46 -05:00
sortTag.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
sortTask.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
unlock.js Login Incentives (#8230) 2016-11-23 19:34:09 -06:00
updateTag.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00
updateTask.js Common reorg (#8025) 2016-09-16 17:18:07 +02:00