fix(Core/Unit): -Wdeprecated-enum-enum-conversion warning (#6868)

This commit is contained in:
Francesco Borzì
2021-07-13 11:51:58 +02:00
committed by GitHub
parent 1fa51e5168
commit f73ef1cd5a
18 changed files with 77 additions and 87 deletions

View File

@@ -4313,7 +4313,7 @@ void AuraEffect::HandleAuraModIncreaseEnergy(AuraApplication const* aurApp, uint
//if (int32(PowerType) != GetMiscValue())
// return;
UnitMods unitMod = UnitMods(UNIT_MOD_POWER_START + PowerType);
UnitMods unitMod = UnitMods(static_cast<uint16>(UNIT_MOD_POWER_START) + PowerType);
target->HandleStatModifier(unitMod, TOTAL_VALUE, float(GetAmount()), apply);
}
@@ -4333,7 +4333,7 @@ void AuraEffect::HandleAuraModIncreaseEnergyPercent(AuraApplication const* aurAp
//if (int32(PowerType) != GetMiscValue())
// return;
UnitMods unitMod = UnitMods(UNIT_MOD_POWER_START + PowerType);
UnitMods unitMod = UnitMods(static_cast<uint16>(UNIT_MOD_POWER_START) + PowerType);
float amount = float(GetAmount());
if (apply)