Skip to content

Commit

Permalink
GO: Add script for bubbly fissure to recast debuff on players nearby
Browse files Browse the repository at this point in the history
Do not ask me why its meant to be like this
  • Loading branch information
killerwife committed May 31, 2024
1 parent 7ead805 commit 299e73b
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
1 change: 1 addition & 0 deletions sql/scriptdev2/scriptdev2.sql
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ UPDATE gameobject_template SET ScriptName='go_midsummer_music' WHERE entry=18817
UPDATE gameobject_template SET ScriptName='go_brewfest_music' WHERE entry=186221;
UPDATE gameobject_template SET ScriptName='go_elemental_rift' WHERE entry IN (179664, 179665, 179666, 179667);
UPDATE gameobject_template SET ScriptName='go_dragon_head' WHERE entry IN(179556,179558,179881,179882);
UPDATE gameobject_template SET ScriptName='go_bubbly_fissure' WHERE entry=177524;
UPDATE gameobject_template SET ScriptName='go_unadorned_spike' WHERE entry IN(175787);
UPDATE gameobject_template SET ScriptName='go_containment_coffer' WHERE entry=122088;
UPDATE gameobject_template SET ScriptName='go_large_jack_o_lantern' WHERE entry=186887;
Expand Down
26 changes: 26 additions & 0 deletions src/game/AI/ScriptDevAI/scripts/world/go_scripts.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -940,6 +940,27 @@ GameObjectAI* GetAI_go_dragon_head(GameObject* go)
return new go_dragon_head(go);
}

enum class GoBubblyFissure
{
SPELL_BUBBLY_FISSURE = 17775,
};

struct go_bubbly_fissure_caster : public GameObjectAI, public TimerManager
{
go_bubbly_fissure_caster(GameObject* go) : GameObjectAI(go)
{
AddCustomAction(1, 2000u, [&]()
{
m_go->CastSpell(nullptr, nullptr, (uint32)GoBubblyFissure::SPELL_BUBBLY_FISSURE, TRIGGERED_OLD_TRIGGERED);
});
}

void UpdateAI(const uint32 diff)
{
UpdateTimers(diff);
}
};

enum
{
SPELL_WARCHIEFS_BLESSING = 16609,
Expand Down Expand Up @@ -1195,6 +1216,11 @@ void AddSC_go_scripts()
pNewScript->GetGameObjectAI = &GetAI_go_dragon_head;
pNewScript->RegisterSelf();

pNewScript = new Script;
pNewScript->Name = "go_bubbly_fissure";
pNewScript->GetGameObjectAI = &GetNewAIInstance<go_bubbly_fissure_caster>;
pNewScript->RegisterSelf();

pNewScript = new Script;
pNewScript->Name = "go_unadorned_spike";
pNewScript->GetGameObjectAI = &GetAI_go_unadorned_spike;
Expand Down

0 comments on commit 299e73b

Please sign in to comment.