mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-20 23:11:56 -04:00
Core/Stats: Removed bonus max mana from intellect
This commit is contained in:
@@ -117,7 +117,6 @@ bool Player::UpdateStats(Stats stat)
|
||||
UpdateMaxHealth();
|
||||
break;
|
||||
case STAT_INTELLECT:
|
||||
UpdateMaxPower(POWER_MANA);
|
||||
UpdateAllSpellCritChances();
|
||||
UpdateArmor(); //SPELL_AURA_MOD_RESISTANCE_OF_INTELLECT_PERCENT, only armor currently
|
||||
break;
|
||||
@@ -266,17 +265,6 @@ float Player::GetHealthBonusFromStamina()
|
||||
return stamina * ratio;
|
||||
}
|
||||
|
||||
float Player::GetManaBonusFromIntellect()
|
||||
{
|
||||
// Taken from PaperDollFrame.lua - 4.3.4.15595
|
||||
float intellect = GetStat(STAT_INTELLECT);
|
||||
|
||||
float baseInt = std::min(20.0f, intellect);
|
||||
float moreInt = intellect - baseInt;
|
||||
|
||||
return baseInt + (moreInt * 15.0f);
|
||||
}
|
||||
|
||||
void Player::UpdateMaxHealth()
|
||||
{
|
||||
UnitMods unitMod = UNIT_MOD_HEALTH;
|
||||
@@ -293,11 +281,9 @@ void Player::UpdateMaxPower(Powers power)
|
||||
{
|
||||
UnitMods unitMod = UnitMods(UNIT_MOD_POWER_START + power);
|
||||
|
||||
float bonusPower = (power == POWER_MANA && GetCreatePowers(power) > 0) ? GetManaBonusFromIntellect() : 0;
|
||||
|
||||
float value = GetModifierValue(unitMod, BASE_VALUE) + GetCreatePowers(power);
|
||||
value *= GetModifierValue(unitMod, BASE_PCT);
|
||||
value += GetModifierValue(unitMod, TOTAL_VALUE) + bonusPower;
|
||||
value += GetModifierValue(unitMod, TOTAL_VALUE);
|
||||
value *= GetModifierValue(unitMod, TOTAL_PCT);
|
||||
|
||||
SetMaxPower(power, uint32(value));
|
||||
|
||||
Reference in New Issue
Block a user