refactor(Core/Unit): minor changes for the combat system (#11904)

Cherry-pick from TC: https://github.com/TrinityCore/TrinityCore/pull/19966

Co-authored-by: Treeston <treeston.nmoc@gmail.com>
This commit is contained in:
Maelthyr
2022-06-14 00:40:29 +02:00
committed by GitHub
parent bf04f280d2
commit 32334f5f14
11 changed files with 39 additions and 42 deletions

View File

@@ -339,7 +339,7 @@ struct boss_priestess_lackey_commonAI : public ScriptedAI
void EnterCombat(Unit* who) override
{
if (Creature* delrissa = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_DELRISSA)))
if (delrissa->IsAlive() && !delrissa->IsInCombat())
if (delrissa->IsAlive() && !delrissa->IsEngaged())
delrissa->AI()->AttackStart(who);
events.ScheduleEvent(EVENT_SPELL_HELPER_HEALING_POTION, 1000);