mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-03-10 19:20:32 +00:00
refactor(Core): AddEventAtOffset (#23140)
This commit is contained in:
@@ -152,7 +152,7 @@ public:
|
||||
if (action == ACTION_INTRO_BALTHARUS && !_introDone)
|
||||
{
|
||||
_introDone = true;
|
||||
me->m_Events.AddEvent(new DelayedTalk(me, SAY_BALTHARUS_INTRO), me->m_Events.CalculateTime(6000));
|
||||
me->m_Events.AddEventAtOffset(new DelayedTalk(me, SAY_BALTHARUS_INTRO), 6s);
|
||||
}
|
||||
else if (action == ACTION_CLONE)
|
||||
{
|
||||
@@ -204,7 +204,7 @@ public:
|
||||
summon->SetHealth(me->GetHealth());
|
||||
summon->CastSpell(summon, SPELL_SPAWN_EFFECT, true);
|
||||
summon->SetReactState(REACT_PASSIVE);
|
||||
summon->m_Events.AddEvent(new RestoreFight(summon), summon->m_Events.CalculateTime(2000));
|
||||
summon->m_Events.AddEventAtOffset(new RestoreFight(summon), 2s);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff) override
|
||||
|
||||
@@ -1120,7 +1120,7 @@ class spell_halion_twilight_realm_aura : public AuraScript
|
||||
target->RemoveAurasDueToSpell(SPELL_FIERY_COMBUSTION, ObjectGuid::Empty, 0, AURA_REMOVE_BY_ENEMY_SPELL);
|
||||
if (!GetTarget()->IsPlayer())
|
||||
return;
|
||||
GetTarget()->m_Events.AddEvent(new SendEncounterUnit(GetTarget()->ToPlayer()), GetTarget()->m_Events.CalculateTime(500));
|
||||
GetTarget()->m_Events.AddEventAtOffset(new SendEncounterUnit(GetTarget()->ToPlayer()), 500ms);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
@@ -1153,7 +1153,7 @@ class spell_halion_leave_twilight_realm_aura : public AuraScript
|
||||
|
||||
if (!GetTarget()->IsPlayer())
|
||||
return;
|
||||
GetTarget()->m_Events.AddEvent(new SendEncounterUnit(GetTarget()->ToPlayer()), GetTarget()->m_Events.CalculateTime(500));
|
||||
GetTarget()->m_Events.AddEventAtOffset(new SendEncounterUnit(GetTarget()->ToPlayer()), 500ms);
|
||||
}
|
||||
|
||||
void Register() override
|
||||
|
||||
Reference in New Issue
Block a user