fix(Core/Scripts): Master of elements odd crash (#13849)

This commit is contained in:
Angelo Venturini 2022-11-21 16:52:08 -03:00 committed by GitHub
parent 9bebd6a05e
commit 9c16f56ccb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -833,6 +833,9 @@ class spell_mage_master_of_elements : public AuraScript
{
PreventDefaultAction();
if (!_spellInfo)
return;
if (Unit* target = GetTarget())
{
int32 mana = int32(_spellInfo->CalcPowerCost(target, eventInfo.GetSchoolMask()) / _ticksModifier);