mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
Scripts/Naxxramas: Fix Frogger event. Closes #16488.
This commit is contained in:
@@ -123,6 +123,9 @@ class instance_naxxramas : public InstanceMapScript
|
||||
CurrentWingTaunt = SAY_KELTHUZAD_FIRST_WING_TAUNT;
|
||||
|
||||
playerDied = 0;
|
||||
|
||||
nextFroggerWave = 0;
|
||||
events.ScheduleEvent(EVENT_SUMMON_FROGGER_WAVE, Seconds(1));
|
||||
}
|
||||
|
||||
void OnCreatureCreate(Creature* creature) override
|
||||
@@ -477,6 +480,16 @@ class instance_naxxramas : public InstanceMapScript
|
||||
kelthuzad->AI()->Talk(CurrentWingTaunt);
|
||||
++CurrentWingTaunt;
|
||||
break;
|
||||
case EVENT_SUMMON_FROGGER_WAVE:
|
||||
{
|
||||
std::list<TempSummon*> spawns;
|
||||
instance->SummonCreatureGroup(nextFroggerWave, &spawns);
|
||||
if (!spawns.empty())
|
||||
(*spawns.begin())->GetMotionMaster()->MovePath(10 * NPC_FROGGER + nextFroggerWave, false);
|
||||
events.Repeat(Seconds(1) + Milliseconds(666));
|
||||
nextFroggerWave = (nextFroggerWave+1) % 3;
|
||||
break;
|
||||
}
|
||||
case EVENT_DIALOGUE_SAPPHIRON_KELTHUZAD:
|
||||
if (Creature* kelthuzad = instance->GetCreature(KelthuzadGUID))
|
||||
kelthuzad->AI()->Talk(SAY_DIALOGUE_SAPPHIRON_KELTHUZAD);
|
||||
@@ -613,6 +626,8 @@ class instance_naxxramas : public InstanceMapScript
|
||||
/* The Immortal / The Undying */
|
||||
uint32 playerDied;
|
||||
|
||||
int8 nextFroggerWave;
|
||||
|
||||
EventMap events;
|
||||
};
|
||||
|
||||
|
||||
@@ -107,7 +107,8 @@ enum CreaturesIds
|
||||
NPC_DK_UNDERSTUDY = 16803,
|
||||
NPC_BIGGLESWORTH = 16998,
|
||||
NPC_LICH_KING = 16980,
|
||||
NPC_OLD_WORLD_TRIGGER = 15384
|
||||
NPC_OLD_WORLD_TRIGGER = 15384,
|
||||
NPC_FROGGER = 16027
|
||||
};
|
||||
|
||||
enum GameObjectsIds
|
||||
@@ -175,6 +176,9 @@ enum InstanceEvents
|
||||
// Dialogue that happens after each wing.
|
||||
EVENT_KELTHUZAD_WING_TAUNT,
|
||||
|
||||
// Periodic Frogger summon
|
||||
EVENT_SUMMON_FROGGER_WAVE,
|
||||
|
||||
// Dialogue that happens after Sapphiron's death.
|
||||
EVENT_DIALOGUE_SAPPHIRON_KELTHUZAD,
|
||||
EVENT_DIALOGUE_SAPPHIRON_LICHKING,
|
||||
|
||||
Reference in New Issue
Block a user