From 96d9b346c105ee543ff1d84c0efe5073bda3ca51 Mon Sep 17 00:00:00 2001 From: kadeshar Date: Sun, 27 Apr 2025 12:39:14 +0200 Subject: [PATCH] Crash fix for teleport action (#1245) * - Crash fix for teleport action * - Revert logic --- src/strategy/actions/TeleportAction.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/strategy/actions/TeleportAction.cpp b/src/strategy/actions/TeleportAction.cpp index cafb6fba..977c7ae5 100644 --- a/src/strategy/actions/TeleportAction.cpp +++ b/src/strategy/actions/TeleportAction.cpp @@ -75,7 +75,7 @@ bool TeleportAction::Execute(Event event) uint32 spellId = goInfo->spellcaster.spellId; SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId); - if (!spellInfo->HasEffect(SPELL_EFFECT_TELEPORT_UNITS)) + if (!spellInfo || !spellInfo->HasEffect(SPELL_EFFECT_TELEPORT_UNITS)) continue; std::ostringstream out;