refactor(Core/ScriptedAI): few improvements with threat methods (#13146)
improve threat scripts Co-authored-by: Maelthyrr <lynethris@protonmail.ch>
This commit is contained in:
+1
-1
@@ -115,7 +115,7 @@ public:
|
||||
case EVENT_KNOCKBACK:
|
||||
DoCastVictim(SPELL_KNOCKBACK);
|
||||
if (DoGetThreat(me->GetVictim()))
|
||||
DoModifyThreatPercent(me->GetVictim(), -50);
|
||||
DoModifyThreatByPercent(me->GetVictim(), -50);
|
||||
events.ScheduleEvent(EVENT_KNOCKBACK, 15000, 30000);
|
||||
break;
|
||||
case EVENT_CHECK:
|
||||
|
||||
@@ -72,7 +72,7 @@ public:
|
||||
case EVENT_WINGBUFFET:
|
||||
DoCastVictim(SPELL_WINGBUFFET);
|
||||
if (DoGetThreat(me->GetVictim()))
|
||||
DoModifyThreatPercent(me->GetVictim(), -75);
|
||||
DoModifyThreatByPercent(me->GetVictim(), -75);
|
||||
events.ScheduleEvent(EVENT_WINGBUFFET, 30000);
|
||||
break;
|
||||
case EVENT_FLAMEBUFFET:
|
||||
|
||||
+1
-1
@@ -77,7 +77,7 @@ public:
|
||||
case EVENT_WINGBUFFET:
|
||||
DoCastVictim(SPELL_WINGBUFFET);
|
||||
if (DoGetThreat(me->GetVictim()))
|
||||
DoModifyThreatPercent(me->GetVictim(), -75);
|
||||
DoModifyThreatByPercent(me->GetVictim(), -75);
|
||||
events.ScheduleEvent(EVENT_WINGBUFFET, 30000);
|
||||
break;
|
||||
case EVENT_FRENZY:
|
||||
|
||||
@@ -411,7 +411,7 @@ public:
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->AttackStop();
|
||||
DoResetThreat();
|
||||
DoResetThreatList();
|
||||
me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_SUBMERGED);
|
||||
DoCastSelf(SPELL_RAGNA_SUBMERGE_VISUAL, true);
|
||||
|
||||
Reference in New Issue
Block a user