fix(Script/Quest): Terokk's Downfall (#24243)

This commit is contained in:
Kitzunu
2025-12-29 14:41:53 +01:00
committed by GitHub
parent ab74e7ded8
commit e46424b8d8
2 changed files with 44 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
--
UPDATE `gameobject_template` SET `AIName` = '', `ScriptName` = 'go_ancient_skull_pile' WHERE `entry` = 185928;
DELETE FROM `smart_scripts` WHERE `entryorguid` = 185928 AND `source_type` = 1;

View File

@@ -572,6 +572,46 @@ private:
SpellCastResult _result;
};
/*######
## go_ancient_skull_pile
######*/
enum AncientSkullPile
{
ITEM_TIME_LOST_OFFERING = 32720,
SPELL_SUMMON_TEROKK = 41004,
GOSSIP_MENU_ANCIENT_SKULL_PILE = 8687,
GOSSIP_MENU_TEXT_ANCIENT_SKULL_PILE = 11058
};
class go_ancient_skull_pile : public GameObjectScript
{
public:
go_ancient_skull_pile() : GameObjectScript("go_ancient_skull_pile") {}
bool OnGossipSelect(Player* player, GameObject* go, uint32 sender, uint32 /*action*/) override
{
ClearGossipMenuFor(player);
if (sender == GOSSIP_SENDER_MAIN)
{
CloseGossipMenuFor(player);
if (player->HasItemCount(ITEM_TIME_LOST_OFFERING, 1))
go->DespawnOrUnsummon();
player->CastSpell(player, SPELL_SUMMON_TEROKK);
}
return true;
}
bool OnGossipHello(Player* player, GameObject* go) override
{
AddGossipItemFor(player, GOSSIP_MENU_ANCIENT_SKULL_PILE, 0, GOSSIP_SENDER_MAIN, 0);
SendGossipMenuFor(player, GOSSIP_MENU_TEXT_ANCIENT_SKULL_PILE, go->GetGUID());
return true;
}
};
/*######
## npc_slim
######*/
@@ -621,5 +661,6 @@ void AddSC_terokkar_forest()
new npc_unkor_the_ruthless();
new npc_isla_starmane();
new go_skull_pile();
new go_ancient_skull_pile();
new npc_slim();
}