mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 10:26:28 +01:00
Scripts/Outland: Fix a potential crash. Closes #17308.
This commit is contained in:
@@ -90,8 +90,10 @@ public:
|
||||
|
||||
void SummonInfernal()
|
||||
{
|
||||
Creature* infernal = me->SummonCreature(NPC_INFERNAL_ATTACKER, me->GetPositionX(), me->GetPositionY(), ground + 0.05f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 60000);
|
||||
infernalGUID = infernal->GetGUID();
|
||||
if (Creature* infernal = me->SummonCreature(NPC_INFERNAL_ATTACKER, me->GetPositionX(), me->GetPositionY(), ground + 0.05f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 60000))
|
||||
infernalGUID = infernal->GetGUID();
|
||||
else
|
||||
infernalGUID = ObjectGuid::Empty;
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff) override
|
||||
|
||||
Reference in New Issue
Block a user