mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 10:55:43 +00:00
fix(Scripts/Scholomance): Fix nullptr crash (#9298)
This commit is contained in:
@@ -296,7 +296,7 @@ public:
|
||||
void SpellHitTarget(Unit* target, const SpellInfo* spellinfo) override
|
||||
{
|
||||
uint32 room = 0;
|
||||
if (spellinfo && spellinfo->Id == SPELL_SHADOW_PORTAL)
|
||||
if (spellinfo && spellinfo->Id == SPELL_SHADOW_PORTAL && target && me->GetVictim())
|
||||
{
|
||||
room = GetData(GANDLING_ROOM_TO_USE);
|
||||
SetGate(room, CLOSED);
|
||||
|
||||
Reference in New Issue
Block a user