aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Argus
diff options
context:
space:
mode:
authorTeleqraph <nyrdeveloper@gmail.com>2023-07-20 19:09:27 +0200
committerGitHub <noreply@github.com>2023-07-20 19:09:27 +0200
commit88ff97c1f96381565c47f8ca1993bdc7fce19fd6 (patch)
treee2b89eb2da0a1a01e8f4eef0a37328e997cb344c /src/server/scripts/Argus
parentd4112334142f85addcf784bf3b4fb3b04773f1cd (diff)
Core/Units: Added helper functions to modify UNIT_FLAG_UNINTERACTIBLE (#29159)
Co-authored-by: Shauren <shauren.trinity@gmail.com>
Diffstat (limited to 'src/server/scripts/Argus')
-rw-r--r--src/server/scripts/Argus/AntorusTheBurningThrone/boss_garothi_worldbreaker.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/server/scripts/Argus/AntorusTheBurningThrone/boss_garothi_worldbreaker.cpp b/src/server/scripts/Argus/AntorusTheBurningThrone/boss_garothi_worldbreaker.cpp
index 699d87986e1..a41787b8efc 100644
--- a/src/server/scripts/Argus/AntorusTheBurningThrone/boss_garothi_worldbreaker.cpp
+++ b/src/server/scripts/Argus/AntorusTheBurningThrone/boss_garothi_worldbreaker.cpp
@@ -254,7 +254,7 @@ struct boss_garothi_worldbreaker : public BossAI
events.Reset();
events.ScheduleEvent(EVENT_REENGAGE_PLAYERS, 3s + 500ms);
HideCannons();
- me->RemoveUnitFlag(UNIT_FLAG_UNINTERACTIBLE);
+ me->SetUninteractible(false);
break;
default:
break;
@@ -278,20 +278,20 @@ struct boss_garothi_worldbreaker : public BossAI
DoCastSelf(SPELL_APOCALYPSE_DRIVE_FINAL_DAMAGE);
Talk(SAY_ANNOUNCE_APOCALYPSE_DRIVE);
Talk(SAY_APOCALYPSE_DRIVE);
- me->SetUnitFlag(UNIT_FLAG_UNINTERACTIBLE);
+ me->SetUninteractible(true);
if (Creature* decimator = instance->GetCreature(DATA_DECIMATOR))
{
instance->SendEncounterUnit(ENCOUNTER_FRAME_ENGAGE, decimator, 2);
decimator->SetUnitFlag(UNIT_FLAG_IN_COMBAT);
- decimator->RemoveUnitFlag(UNIT_FLAG_UNINTERACTIBLE);
+ decimator->SetUninteractible(false);
}
if (Creature* annihilator = instance->GetCreature(DATA_ANNIHILATOR))
{
instance->SendEncounterUnit(ENCOUNTER_FRAME_ENGAGE, annihilator, 2);
annihilator->SetUnitFlag(UNIT_FLAG_IN_COMBAT);
- annihilator->RemoveUnitFlag(UNIT_FLAG_UNINTERACTIBLE);
+ annihilator->SetUninteractible(false);
}
++_apocalypseDriveCount;
}
@@ -326,7 +326,7 @@ struct boss_garothi_worldbreaker : public BossAI
case NPC_ANNIHILATOR:
me->InterruptNonMeleeSpells(true);
me->RemoveAurasDueToSpell(SPELL_APOCALYPSE_DRIVE);
- me->RemoveUnitFlag(UNIT_FLAG_UNINTERACTIBLE);
+ me->SetUninteractible(false);
if (summon->GetEntry() == NPC_ANNIHILATOR)
_searingBarrageSpellId = SPELL_SEARING_BARRAGE_ANNIHILATOR;
@@ -455,13 +455,15 @@ struct boss_garothi_worldbreaker : public BossAI
if (Creature* decimator = instance->GetCreature(DATA_DECIMATOR))
{
instance->SendEncounterUnit(ENCOUNTER_FRAME_DISENGAGE, decimator);
- decimator->SetUnitFlag(UNIT_FLAG_UNINTERACTIBLE | UNIT_FLAG_IMMUNE);
+ decimator->SetUninteractible(true);
+ decimator->SetUnitFlag(UNIT_FLAG_IMMUNE);
}
if (Creature* annihilator = instance->GetCreature(DATA_ANNIHILATOR))
{
instance->SendEncounterUnit(ENCOUNTER_FRAME_DISENGAGE, annihilator);
- annihilator->SetUnitFlag(UNIT_FLAG_UNINTERACTIBLE | UNIT_FLAG_IMMUNE);
+ annihilator->SetUninteractible(true);
+ annihilator->SetUnitFlag(UNIT_FLAG_IMMUNE);
}
}
};