mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-15 18:10:26 +00:00
@@ -4288,6 +4288,46 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
enum GoblinBomb
|
||||
{
|
||||
SPELL_SUMMON_GOBLIN_BOMB = 13258,
|
||||
};
|
||||
|
||||
// 23134 - Goblin Bomb
|
||||
class spell_item_goblin_bomb : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_item_goblin_bomb() : SpellScriptLoader("spell_item_goblin_bomb") {}
|
||||
|
||||
class spell_item_goblin_bomb_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_item_goblin_bomb_SpellScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/) override
|
||||
{
|
||||
return ValidateSpellInfo({ SPELL_SUMMON_GOBLIN_BOMB });
|
||||
}
|
||||
|
||||
void HandleDummy(SpellEffIndex /*effIndex*/)
|
||||
{
|
||||
if (Unit* caster = GetCaster())
|
||||
{
|
||||
caster->CastSpell(caster, SPELL_SUMMON_GOBLIN_BOMB, true, GetCastItem());
|
||||
}
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHit += SpellEffectFn(spell_item_goblin_bomb_SpellScript::HandleDummy, EFFECT_0, SPELL_EFFECT_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_item_goblin_bomb_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_item_spell_scripts()
|
||||
{
|
||||
// Ours
|
||||
@@ -4395,4 +4435,5 @@ void AddSC_item_spell_scripts()
|
||||
new spell_item_muisek_vessel();
|
||||
new spell_item_greatmothers_soulcatcher();
|
||||
new spell_item_eggnog();
|
||||
new spell_item_goblin_bomb();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user