From b1a9e60c8e7c5ce1fe1583e2cf588964e9181366 Mon Sep 17 00:00:00 2001 From: Tyler Renelle Date: Sat, 21 Dec 2013 16:40:36 -0700 Subject: [PATCH] stats.mp++ when completing todos @wc8 @danielthebard --- dist/habitrpg-shared.js | 3 +++ script/index.coffee | 1 + 2 files changed, 4 insertions(+) diff --git a/dist/habitrpg-shared.js b/dist/habitrpg-shared.js index 0e3d1cf3a9..de776987ec 100644 --- a/dist/habitrpg-shared.js +++ b/dist/habitrpg-shared.js @@ -11677,6 +11677,9 @@ var process=require("__browserify_process");(function() { } else { calculateDelta(); addPoints(); + if (!(user.stats.mp >= user._statsComputed.maxMP)) { + user.stats.mp++; + } } break; case 'reward': diff --git a/script/index.coffee b/script/index.coffee index 063fcd6a5a..bb7c334930 100644 --- a/script/index.coffee +++ b/script/index.coffee @@ -762,6 +762,7 @@ api.wrap = (user) -> else calculateDelta() addPoints() # obviously for delta>0, but also a trick to undo accidental checkboxes + user.stats.mp++ unless user.stats.mp >= user._statsComputed.maxMP when 'reward' # Don't adjust values for rewards