Uldaman altar event left broken after #541 (#745)

* add gohello function

* check ritualPersistent before finish uses
This commit is contained in:
sipertruk
2017-05-17 06:46:24 +02:00
committed by StadenElysium
parent c86d34f95e
commit df958d338c
3 changed files with 30 additions and 1 deletions
@@ -383,6 +383,20 @@ SDComment: Needs 1 person to activate the Archaedas script
SDCategory: Uldaman
EndScriptData */
bool GOHello_go_altar_of_archaedas(Player* pPlayer, GameObject* pGo)
{
ScriptedInstance* pInstance = (ScriptedInstance*)pGo->GetInstanceData();
if (!pInstance)
return false;
if (pPlayer)
pPlayer->CastSpell(nullptr, SPELL_ALTAR_SUMMONING_VISUAL, true);
return true;
}
class go_altar_of_archaedasAI : public GameObjectAI
{
public:
@@ -500,5 +514,6 @@ void AddSC_boss_archaedas()
newscript = new Script;
newscript->Name = "go_altar_of_archaedas";
newscript->GOGetAI = &GetAI_go_altar_of_archaedas;
newscript->pGOHello = &GOHello_go_altar_of_archaedas;
newscript->RegisterSelf();
}
@@ -280,6 +280,19 @@ bool OnTrigger_at_map_chamber(Player* pPlayer, const AreaTriggerEntry *at)
return true;
}
bool GOHello_go_altar_of_the_keepers(Player* pPlayer, GameObject* pGo)
{
ScriptedInstance* pInstance = (ScriptedInstance*)pGo->GetInstanceData();
if (!pInstance)
return false;
if (pPlayer)
pPlayer->CastSpell(nullptr, SPELL_ALTAR_SUMMONING_VISUAL, true);
return true;
}
class go_altar_of_the_keepersAI : public GameObjectAI
{
public:
@@ -522,6 +535,7 @@ void AddSC_uldaman()
newscript = new Script;
newscript->Name = "go_altar_of_the_keepers";
newscript->GOGetAI = &GetAI_go_altar_of_the_keepers;
newscript->pGOHello = &GOHello_go_altar_of_the_keepers;
newscript->RegisterSelf();
newscript = new Script;