Core/Creature: Add facilities to the Creature class to allow setting an automated, periodic pulse that puts every player in the zone in combat and on the creature's threat list.
Scripts/BossAI: Set the BossAI parent class to make use of this in its _EnterCombat and _Reset methods. Combat pulses happen every 5 seconds. (cherry picked from commit d57193df444b719757ae1da4a5f19e204074f6ae) # Conflicts: # src/server/game/AI/ScriptedAI/ScriptedCreature.cpp # src/server/game/Entities/Creature/Creature.cpp
This commit is contained in:
@@ -453,6 +453,7 @@ void BossAI::_Reset()
|
||||
if (!me->IsAlive())
|
||||
return;
|
||||
|
||||
me->SetCombatPulseDelay(0);
|
||||
me->ResetLootMode();
|
||||
events.Reset();
|
||||
summons.DespawnAll();
|
||||
@@ -470,6 +471,7 @@ void BossAI::_JustDied()
|
||||
|
||||
void BossAI::_EnterCombat()
|
||||
{
|
||||
me->SetCombatPulseDelay(5);
|
||||
me->setActive(true);
|
||||
DoZoneInCombat();
|
||||
if (instance)
|
||||
|
||||
Reference in New Issue
Block a user