Merge 21145903f56d8d6e6f433a896e6c5f614a3791ca into 5bef92d5eaca3e2ecc317f9d599312bc23eb71aa

This commit is contained in:
Luca Folloni 2025-11-09 23:19:33 +00:00 committed by GitHub
commit eb980bc64b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -152,7 +152,12 @@ class spell_dk_raise_ally : public SpellScript
SpellCastResult CheckCast()
{
Player* unitTarget = GetHitPlayer();
ObjectGuid targetGuid = GetSpell()->m_targets.GetUnitTargetGUID();
if (!targetGuid)
return SPELL_FAILED_BAD_TARGETS;
Unit* target = ObjectAccessor::GetUnit(*(GetSpell()->GetCaster()), targetGuid);
Player* unitTarget = target ? target->ToPlayer() : nullptr;
if (!unitTarget)
return SPELL_FAILED_BAD_TARGETS;