mirror of
https://github.com/azerothcore/azerothcore-wotlk.git
synced 2025-11-10 12:24:22 +08:00
Merge 41d7001566bd2b6f825fe13f15fd4527ca62f72a into 125e1aec9d593a7c6bbff899ee66a6e2f1fcee9c
This commit is contained in:
commit
db2c82c3c7
@ -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;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user