diff options
| author | ariel- <ariel-@users.noreply.github.com> | 2018-01-18 13:58:40 -0300 |
|---|---|---|
| committer | ariel- <ariel-@users.noreply.github.com> | 2018-01-18 13:58:40 -0300 |
| commit | 0db5c2df3fe56f42293865e87ec781cd4d41598b (patch) | |
| tree | df671abc0631637261038f17841adc7c417caf16 /src/server/scripts/EasternKingdoms/Karazhan | |
| parent | d9d26200f7ffc07507dfca4a2c17fdfcde0194c8 (diff) | |
Core/Scripts: added nullptr checks to DamageTaken hooks
Since cb9e72e521d3cc415dd15bf6912c87f89e41b92a attacker may not be in world when hook is called
Diffstat (limited to 'src/server/scripts/EasternKingdoms/Karazhan')
| -rw-r--r-- | src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp index 462a40687c4..e26faff6449 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp @@ -168,7 +168,7 @@ public: void DamageTaken(Unit* done_by, uint32 &damage) override { - if (done_by->GetGUID() != malchezaar) + if (!done_by || done_by->GetGUID() != malchezaar) damage = 0; } |
