mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Warning fix
This commit is contained in:
@@ -1843,7 +1843,7 @@ void Player::Regenerate(Powers power)
|
||||
if (HasAuraTypeWithValue(SPELL_AURA_PREVENT_REGENERATE_POWER, power))
|
||||
return;
|
||||
|
||||
uint32 curValue = GetPower(power);
|
||||
int32 curValue = GetPower(power);
|
||||
|
||||
// TODO: updating haste should update UNIT_FIELD_POWER_REGEN_FLAT_MODIFIER for certain power types
|
||||
PowerTypeEntry const* powerType = sDB2Manager.GetPowerTypeEntry(power);
|
||||
@@ -1909,7 +1909,7 @@ void Player::Regenerate(Powers power)
|
||||
|
||||
if (addvalue < 0.0f)
|
||||
{
|
||||
if (curValue > integerValue + minPower)
|
||||
if (curValue > minPower + integerValue)
|
||||
{
|
||||
curValue -= integerValue;
|
||||
m_powerFraction[powerIndex] = addvalue + integerValue;
|
||||
|
||||
Reference in New Issue
Block a user