mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-28 08:06:23 +00:00
fix(Scripts/ManaTombs): Pandemonius should aggro the enitre room (#17764)
* fix(Scripts/ManaTombs): Pandemonius should aggro the enitre room * how does this work * .
This commit is contained in:
@@ -39,6 +39,17 @@ enum Groups
|
||||
GROUP_VOID_BLAST = 1
|
||||
};
|
||||
|
||||
enum RoomAdds
|
||||
{
|
||||
NPC_SCAVENGER = 18309,
|
||||
NPC_CRYPT_RAIDER = 18311,
|
||||
NPC_SORCERER = 18313,
|
||||
};
|
||||
|
||||
float const ROOM_PULL_RANGE = 70.0f;
|
||||
float const ROOM_ENTERANCE = -50.0f;
|
||||
float const ROOM_EXIT = -145.0f;
|
||||
|
||||
constexpr uint8 MAX_VOID_BLAST = 5;
|
||||
|
||||
struct boss_pandemonius : public BossAI
|
||||
@@ -68,18 +79,22 @@ struct boss_pandemonius : public BossAI
|
||||
context.Repeat();
|
||||
})
|
||||
.Schedule(8s, 23s, [this](TaskContext context)
|
||||
{
|
||||
if (!(context.GetRepeatCounter() % (MAX_VOID_BLAST + 1)))
|
||||
{
|
||||
if (!(context.GetRepeatCounter() % (MAX_VOID_BLAST + 1)))
|
||||
{
|
||||
context.Repeat(15s, 25s);
|
||||
}
|
||||
else
|
||||
{
|
||||
DoCastRandomTarget(SPELL_VOID_BLAST);
|
||||
context.Repeat(500ms);
|
||||
context.DelayGroup(GROUP_VOID_BLAST, 500ms);
|
||||
}
|
||||
});
|
||||
context.Repeat(15s, 25s);
|
||||
}
|
||||
else
|
||||
{
|
||||
DoCastRandomTarget(SPELL_VOID_BLAST);
|
||||
context.Repeat(500ms);
|
||||
context.DelayGroup(GROUP_VOID_BLAST, 500ms);
|
||||
}
|
||||
})
|
||||
.Schedule(0s, [this](TaskContext)
|
||||
{
|
||||
PullRoom();
|
||||
});
|
||||
|
||||
BossAI::JustEngagedWith(who);
|
||||
}
|
||||
@@ -95,6 +110,22 @@ struct boss_pandemonius : public BossAI
|
||||
Talk(SAY_DEATH);
|
||||
BossAI::JustDied(killer);
|
||||
}
|
||||
|
||||
void PullRoom()
|
||||
{
|
||||
std::list<Creature*> creatureList;
|
||||
GetCreatureListWithEntryInGrid(creatureList, me, NPC_SCAVENGER, ROOM_PULL_RANGE);
|
||||
GetCreatureListWithEntryInGrid(creatureList, me, NPC_CRYPT_RAIDER, ROOM_PULL_RANGE);
|
||||
GetCreatureListWithEntryInGrid(creatureList, me, NPC_SORCERER, ROOM_PULL_RANGE);
|
||||
for (Creature* creature : creatureList)
|
||||
{
|
||||
if (creature && (creature->GetPositionY() < ROOM_ENTERANCE && creature->GetPositionY() > ROOM_EXIT))
|
||||
{
|
||||
creature->SetInCombatWithZone();
|
||||
}
|
||||
}
|
||||
creatureList.clear();
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_boss_pandemonius()
|
||||
|
||||
Reference in New Issue
Block a user