diff --git a/dist/habitrpg-shared.js b/dist/habitrpg-shared.js index 0e3d1cf3a9..383c1edb73 100644 --- a/dist/habitrpg-shared.js +++ b/dist/habitrpg-shared.js @@ -11911,6 +11911,7 @@ var process=require("__browserify_process");(function() { stats.exp = 0; } user.stats.hp = 50; + user.stats.mp = user._statsComputed.maxMP; } } user.stats.exp = stats.exp; @@ -12065,6 +12066,10 @@ var process=require("__browserify_process");(function() { stealth: 0, streaks: false }; + user.stats.mp += Math.ceil(user._statsComputed.int * .15); + if (user.stats.mp > user._statsComputed.maxMP) { + user.stats.mp = user._statsComputed.maxMP; + } return user; }, preenUserHistory: function(minHistLen) { diff --git a/script/index.coffee b/script/index.coffee index 063fcd6a5a..39be8ecad0 100644 --- a/script/index.coffee +++ b/script/index.coffee @@ -970,6 +970,7 @@ api.wrap = (user) -> if user.stats.lvl == 100 stats.exp = 0 user.stats.hp = 50 + user.stats.mp = user._statsComputed.maxMP user.stats.exp = stats.exp # Set flags when they unlock features @@ -1081,6 +1082,9 @@ api.wrap = (user) -> user.markModified? 'history' user.markModified? 'dailys' # covers dailys.*.history user.stats.buffs = {str:0,int:0,per:0,con:0,stealth:0,streaks:false} + user.stats.mp += Math.ceil(user._statsComputed.int * .15) + if user.stats.mp > user._statsComputed.maxMP + user.stats.mp = user._statsComputed.maxMP user # Registered users with some history