aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts
diff options
context:
space:
mode:
authorTreeston <treeston.mmoc@gmail.com>2017-07-25 02:01:32 +0200
committerShauren <shauren.trinity@gmail.com>2020-08-20 00:21:37 +0200
commite69b5d8fcc44728abd189e4832a383543218e5c1 (patch)
treeb93a6ac1283ca363444b6dcfcf93d0f340a1dd97 /src/server/scripts
parent9757a2992a5127d24e6592540112d7de6cd8c8b6 (diff)
Scripts/IcecrownCitadel: Prevent players from becoming inaccessible when killed by Lord Marrowgar's Impale spell (the initial damage, not the DoT). Also fix the underlying bug in vehicle logic.
(cherry picked from commit 7cbb6c101e975a046b95aeb5dd68d75d016f67a5)
Diffstat (limited to 'src/server/scripts')
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
index 4efe13e02c9..c432352bdea 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
@@ -654,6 +654,15 @@ class spell_marrowgar_bone_spike_graveyard : public SpellScriptLoader
{
Unit* target = *itr;
target->CastSpell(target, BoneSpikeSummonId[i], true);
+ if (!target->IsAlive()) // make sure we don't get any stuck spikes on dead targets
+ {
+ if (Aura* aura = target->GetAura(SPELL_IMPALED))
+ {
+ if (Creature* spike = ObjectAccessor::GetCreature(*target, aura->GetCasterGUID()))
+ spike->DespawnOrUnsummon();
+ aura->Remove();
+ }
+ }
}
marrowgarAI->Talk(SAY_BONESPIKE);