aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/world/master/2021_06_19_19_world_2018_02_11_02_world_335.sql3
-rw-r--r--src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp21
2 files changed, 24 insertions, 0 deletions
diff --git a/sql/updates/world/master/2021_06_19_19_world_2018_02_11_02_world_335.sql b/sql/updates/world/master/2021_06_19_19_world_2018_02_11_02_world_335.sql
new file mode 100644
index 00000000000..5a98c0da863
--- /dev/null
+++ b/sql/updates/world/master/2021_06_19_19_world_2018_02_11_02_world_335.sql
@@ -0,0 +1,3 @@
+DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_combined_toxins';
+INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
+(56584, 'spell_combined_toxins');
diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp
index b9ff99c1cc4..a80530aec30 100644
--- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp
+++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp
@@ -22,6 +22,8 @@
#include "GameObject.h"
#include "InstanceScript.h"
#include "Map.h"
+#include "SpellInfo.h"
+#include "SpellScript.h"
#include <sstream>
DoorData const doorData[] =
@@ -150,7 +152,26 @@ class instance_ahnkahet : public InstanceMapScript
}
};
+// 56584 - Combined Toxins
+class spell_combined_toxins : public AuraScript
+{
+ PrepareAuraScript(spell_combined_toxins);
+
+ bool CheckProc(AuraEffect const* /*aurEff*/, ProcEventInfo& eventInfo)
+ {
+ // only procs on poisons (damage class check to exclude stuff like Envenom)
+ SpellInfo const* spellInfo = eventInfo.GetSpellInfo();
+ return (spellInfo && spellInfo->Dispel == DISPEL_POISON && spellInfo->DmgClass != SPELL_DAMAGE_CLASS_MELEE);
+ }
+
+ void Register() override
+ {
+ DoCheckEffectProc += AuraCheckEffectProcFn(spell_combined_toxins::CheckProc, EFFECT_0, SPELL_AURA_PROC_TRIGGER_DAMAGE);
+ }
+};
+
void AddSC_instance_ahnkahet()
{
new instance_ahnkahet();
+ RegisterAuraScript(spell_combined_toxins);
}