mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-02 10:33:46 +00:00
Core/Combat: rename getThreatMgr() to GetThreatMgr() (#11758)
This commit is contained in:
@@ -91,8 +91,8 @@ public:
|
||||
if (Unit* target = me->GetVictim())
|
||||
{
|
||||
_conflagrateTarget = me->GetVictim()->GetGUID();
|
||||
_conflagrateThreat = me->getThreatMgr().getThreat(me->GetVictim());
|
||||
me->getThreatMgr().modifyThreatPercent(target, -100);
|
||||
_conflagrateThreat = me->GetThreatMgr().getThreat(me->GetVictim());
|
||||
me->GetThreatMgr().modifyThreatPercent(target, -100);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_CONFLAGRATION, urand(10000, 13000));
|
||||
events.ScheduleEvent(EVENT_CHECK_CONFLAGRATION_TARGET, 10000);
|
||||
@@ -112,7 +112,7 @@ public:
|
||||
case EVENT_CHECK_CONFLAGRATION_TARGET:
|
||||
if (Unit* target = ObjectAccessor::GetUnit(*me, _conflagrateTarget))
|
||||
{
|
||||
me->getThreatMgr().addThreat(target, _conflagrateThreat);
|
||||
me->GetThreatMgr().addThreat(target, _conflagrateThreat);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -122,13 +122,13 @@ struct boss_mor_grayhoof : public BossAI
|
||||
|
||||
// Sleep can target tank, we need to drop threat temporarily on the target.
|
||||
_sleepTargetGUID = target->GetGUID();
|
||||
_sleepTargetThreat = me->getThreatMgr().getThreat(target);
|
||||
me->getThreatMgr().modifyThreatPercent(target, -100);
|
||||
_sleepTargetThreat = me->GetThreatMgr().getThreat(target);
|
||||
me->GetThreatMgr().modifyThreatPercent(target, -100);
|
||||
_scheduler.Schedule(10s, [this](TaskContext /*context*/)
|
||||
{
|
||||
if (Unit* sleepTarget = ObjectAccessor::GetUnit(*me, _sleepTargetGUID))
|
||||
{
|
||||
me->getThreatMgr().addThreat(sleepTarget, _sleepTargetThreat);
|
||||
me->GetThreatMgr().addThreat(sleepTarget, _sleepTargetThreat);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -674,7 +674,7 @@ struct boss_nefarian : public BossAI
|
||||
break;
|
||||
case EVENT_CLASSCALL:
|
||||
std::set<uint8> classesPresent;
|
||||
for (auto& ref : me->getThreatMgr().getThreatList())
|
||||
for (auto& ref : me->GetThreatMgr().getThreatList())
|
||||
{
|
||||
if (ref->getTarget() && ref->getTarget()->GetTypeId() == TYPEID_PLAYER)
|
||||
{
|
||||
|
||||
@@ -597,7 +597,7 @@ public:
|
||||
{
|
||||
if (Creature* creatureCaster = caster->ToCreature())
|
||||
{
|
||||
creatureCaster->getThreatMgr().ResetAllThreat();
|
||||
creatureCaster->GetThreatMgr().ResetAllThreat();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -234,7 +234,7 @@ public:
|
||||
|
||||
void EnterEvadeMode(EvadeReason why) override
|
||||
{
|
||||
if (!me->getThreatMgr().getThreatList().empty())
|
||||
if (!me->GetThreatMgr().getThreatList().empty())
|
||||
{
|
||||
if (!_processingMagmaBurst)
|
||||
{
|
||||
|
||||
@@ -170,8 +170,8 @@ public:
|
||||
|
||||
if (Creature* creatureCaster = caster->ToCreature())
|
||||
{
|
||||
creatureCaster->getThreatMgr().ResetAllThreat();
|
||||
creatureCaster->getThreatMgr().addThreat(target, 1);
|
||||
creatureCaster->GetThreatMgr().ResetAllThreat();
|
||||
creatureCaster->GetThreatMgr().addThreat(target, 1);
|
||||
creatureCaster->AI()->AttackStart(target); // Attack the target which caster will teleport to.
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user