fix(Core/Unit): rework Walk/Run mode (#22988)
Co-authored-by: sudlud <sudlud@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
parent
c28f635408
commit
10d5a3c553
104 changed files with 373 additions and 362 deletions
|
|
@ -359,7 +359,7 @@ public:
|
|||
case 0:
|
||||
Talk(SAY_TEXT5);
|
||||
HandleGameObject(DATA_ARENA4, false);
|
||||
Start(false, false);
|
||||
Start(false);
|
||||
eventTimer = 0;
|
||||
break;
|
||||
case 1:
|
||||
|
|
@ -604,7 +604,7 @@ public:
|
|||
creature->CastSpell(creature, SPELL_DRUNKEN_RAGE, false);
|
||||
|
||||
if (npc_escortAI* escortAI = CAST_AI(npc_rocknot::npc_rocknotAI, creature->AI()))
|
||||
escortAI->Start(false, false);
|
||||
escortAI->Start(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -77,7 +77,9 @@ struct boss_quartermaster_zigris : public BossAI
|
|||
{
|
||||
if (me->IsWithinMeleeRange(me->GetVictim()))
|
||||
{
|
||||
me->GetMotionMaster()->MoveBackwards(me->GetVictim(), 10.0f);
|
||||
float x, y, z;
|
||||
me->GetNearPoint(me->GetVictim(), x, y, z, me->GetVictim()->GetBoundaryRadius(), 10.0f, me->GetAngle(me->GetVictim()));
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_RUN); // TODO: Implement generic distancing on npc on target root
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -430,7 +430,7 @@ public:
|
|||
Talk(SAY_RAG_SUM_2);
|
||||
// Next event will get triggered in MovementInform
|
||||
me->SetWalk(true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_RAGNAROS_SUMMON, MajordomoMoveRagPos, true, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_RAGNAROS_SUMMON, MajordomoMoveRagPos, FORCED_MOVEMENT_NONE, 0.f, true, false);
|
||||
break;
|
||||
}
|
||||
case EVENT_RAGNAROS_SUMMON_2:
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ public:
|
|||
if (m_uiEventId == EVENT_OZ)
|
||||
instance->SetData(DATA_OPERA_OZ_DEATHCOUNT, IN_PROGRESS);
|
||||
|
||||
Start(false, false);
|
||||
Start(false);
|
||||
}
|
||||
|
||||
void JustEngagedWith(Unit* /*who*/) override { }
|
||||
|
|
|
|||
|
|
@ -980,7 +980,7 @@ public:
|
|||
{
|
||||
carGUID = who->GetVehicleBase()->GetGUID();
|
||||
InitWaypoint();
|
||||
Start(false, false, who->GetGUID());
|
||||
Start(false, who->GetGUID());
|
||||
SetDespawnAtFar(false);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -660,14 +660,14 @@ public:
|
|||
{
|
||||
Position pos = LightOfDawnPos[first];
|
||||
summon->SetHomePosition(pos);
|
||||
summon->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), true, false);
|
||||
summon->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, true, false);
|
||||
}
|
||||
first = first == 0 ? 1 : 0;
|
||||
}
|
||||
Position pos = LightOfDawnPos[first];
|
||||
me->SetHomePosition(pos);
|
||||
me->SetWalk(false);
|
||||
me->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), true, true);
|
||||
me->GetMotionMaster()->MovePoint(1, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, true, true);
|
||||
DoCastSelf(SPELL_THE_MIGHT_OF_MOGRAINE, true);
|
||||
break;
|
||||
}
|
||||
|
|
@ -691,7 +691,7 @@ public:
|
|||
{
|
||||
orbaz->SetReactState(REACT_PASSIVE);
|
||||
orbaz->AI()->Talk(EMOTE_LIGHT_OF_DAWN04);
|
||||
orbaz->GetMotionMaster()->MovePoint(2, LightOfDawnPos[2], true, true);
|
||||
orbaz->GetMotionMaster()->MovePoint(2, LightOfDawnPos[2], FORCED_MOVEMENT_NONE, 0.f, true, true);
|
||||
orbaz->DespawnOrUnsummon(7s);
|
||||
}
|
||||
|
||||
|
|
@ -1061,7 +1061,7 @@ public:
|
|||
if (Creature* tirion = GetEntryFromSummons(NPC_HIGHLORD_TIRION_FORDRING))
|
||||
{
|
||||
float o = me->GetAngle(tirion);
|
||||
tirion->GetMotionMaster()->MovePoint(4, me->GetPositionX() + 2.0f * cos(o), me->GetPositionY() + 2.0f * std::sin(o), me->GetPositionZ(), false);
|
||||
tirion->GetMotionMaster()->MovePoint(4, me->GetPositionX() + 2.0f * cos(o), me->GetPositionY() + 2.0f * std::sin(o), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
tirion->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE);
|
||||
tirion->SetFaction(FACTION_FRIENDLY);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -304,7 +304,7 @@ struct npc_madrigosa : public NullCreatureAI
|
|||
if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS))
|
||||
{
|
||||
brutallus->SetDisableGravity(true);
|
||||
brutallus->GetMotionMaster()->MovePoint(0, brutallus->GetPositionX(), brutallus->GetPositionY() - 30.0f, brutallus->GetPositionZ() + 15.0f, false, true);
|
||||
brutallus->GetMotionMaster()->MovePoint(0, brutallus->GetPositionX(), brutallus->GetPositionY() - 30.0f, brutallus->GetPositionZ() + 15.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, true);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_MAD_15, 10s);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -205,7 +205,7 @@ struct boss_felmyst : public BossAI
|
|||
|
||||
// Summon Kalecgos (human form of kalecgos fight)
|
||||
if (Creature* kalec = me->SummonCreature(NPC_KALECGOS_FELMYST, 1573.1461f, 755.20245f, 99.524956f, 3.595378f))
|
||||
kalec->GetMotionMaster()->MovePoint(POINT_KALECGOS, 1474.2347f, 624.0703f, 29.32589f, false, true);
|
||||
kalec->GetMotionMaster()->MovePoint(POINT_KALECGOS, 1474.2347f, 624.0703f, 29.32589f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, true);
|
||||
}
|
||||
|
||||
void ScheduleGroundAbilities()
|
||||
|
|
@ -312,9 +312,9 @@ struct boss_felmyst : public BossAI
|
|||
++_strafeCount;
|
||||
_currentLane = urand(0, 2);
|
||||
if (isRightSide)
|
||||
me->GetMotionMaster()->MovePoint(POINT_LANE, RightSideLanes[_currentLane], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_LANE, RightSideLanes[_currentLane], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
else
|
||||
me->GetMotionMaster()->MovePoint(POINT_LANE, LeftSideLanes[_currentLane], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_LANE, LeftSideLanes[_currentLane], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}, 5s);
|
||||
break;
|
||||
case POINT_LANE:
|
||||
|
|
@ -328,9 +328,9 @@ struct boss_felmyst : public BossAI
|
|||
DoCastSelf(SPELL_FELMYST_SPEED_BURST, true);
|
||||
|
||||
if (me->FindNearestCreature(NPC_WORLD_TRIGGER_RIGHT, 30.0f))
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END, LeftSideLanes[_currentLane], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END, LeftSideLanes[_currentLane], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
else
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END, RightSideLanes[_currentLane], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END, RightSideLanes[_currentLane], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}, 5s);
|
||||
break;
|
||||
case POINT_AIR_BREATH_END:
|
||||
|
|
@ -338,9 +338,9 @@ struct boss_felmyst : public BossAI
|
|||
|
||||
me->m_Events.AddEventAtOffset([&] {
|
||||
if (me->FindNearestCreature(NPC_WORLD_TRIGGER_RIGHT, 30.0f))
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_UP, RightSide, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_UP, RightSide, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
else
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_UP, LeftSide, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_AIR_UP, LeftSide, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}, 2s);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -729,25 +729,18 @@ struct npc_kalecgos_kj : public NullCreatureAI
|
|||
if (summon->GetEntry() == NPC_SHATTERED_SUN_RIFTWAKER)
|
||||
{
|
||||
summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true);
|
||||
Movement::MoveSplineInit init(summon);
|
||||
|
||||
if (summons.size() == 1)
|
||||
{
|
||||
init.MoveTo(1727.08f, 656.82f, 28.37f, false, true);
|
||||
init.SetFacing(5.14f);
|
||||
}
|
||||
summon->GetMotionMaster()->MovePoint(0, 1727.08f, 656.82f, 28.37f, FORCED_MOVEMENT_NONE, 0.f, 5.14f, false, true);
|
||||
else
|
||||
{
|
||||
init.MoveTo(1738.84f, 627.32f, 28.26f, false, true);
|
||||
init.SetFacing(2.0f);
|
||||
}
|
||||
init.Launch();
|
||||
summon->GetMotionMaster()->MovePoint(0, 1738.84f, 627.32f, 28.26f, FORCED_MOVEMENT_NONE, 0.f, 2.0f, false, true);
|
||||
}
|
||||
else if (summon->GetEntry() == NPC_SHATTRATH_PORTAL_DUMMY)
|
||||
{
|
||||
if (Creature* riftwaker = summon->FindNearestCreature(NPC_SHATTERED_SUN_RIFTWAKER, 10.0f))
|
||||
riftwaker->CastSpell(summon, SPELL_OPEN_PORTAL_FROM_SHATTRATH, false);
|
||||
summon->SetWalk(true);
|
||||
summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 30.0f, false, true);
|
||||
summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 30.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, true);
|
||||
}
|
||||
else if (summon->GetEntry() == NPC_INERT_PORTAL)
|
||||
summon->CastSpell(summon, SPELL_BOSS_ARCANE_PORTAL_STATE, true);
|
||||
|
|
@ -762,7 +755,7 @@ struct npc_kalecgos_kj : public NullCreatureAI
|
|||
{
|
||||
summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true);
|
||||
summon->SetWalk(true);
|
||||
summon->GetMotionMaster()->MovePoint(0, 1710.15f, 639.23f, 27.311f, false, true);
|
||||
summon->GetMotionMaster()->MovePoint(0, 1710.15f, 639.23f, 27.311f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, true);
|
||||
}
|
||||
else if (summon->GetEntry() == NPC_THE_CORE_OF_ENTROPIUS)
|
||||
summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), 30.0f);
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ public:
|
|||
break;
|
||||
case 11:
|
||||
Talk(SAY_PROGRESS_6, player);
|
||||
SetRun();
|
||||
SetRun(true);
|
||||
break;
|
||||
case 19:
|
||||
Talk(SAY_PROGRESS_7, player);
|
||||
|
|
@ -106,7 +106,7 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_SUNKEN_TREASURE)
|
||||
{
|
||||
Talk(SAY_PROGRESS_1, player);
|
||||
npc_escortAI::Start(false, false, player->GetGUID(), quest);
|
||||
npc_escortAI::Start(false, player->GetGUID(), quest);
|
||||
me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -112,11 +112,11 @@ struct npc_cameron : public ScriptedAI
|
|||
if (Creature* children = ObjectAccessor::GetCreature(*me, _childrenGUIDs[i]))
|
||||
{
|
||||
children->SetWalk(true);
|
||||
children->GetMotionMaster()->MovePoint(0, MovePosPositions[i], true, MovePosPositions[i].GetOrientation());
|
||||
children->GetMotionMaster()->MovePoint(0, MovePosPositions[i]);
|
||||
}
|
||||
}
|
||||
me->SetWalk(true);
|
||||
me->GetMotionMaster()->MovePoint(0, MovePosPositions.back(), true, MovePosPositions.back().GetOrientation());
|
||||
me->GetMotionMaster()->MovePoint(0, MovePosPositions.back());
|
||||
}
|
||||
|
||||
void PathEndReached(uint32 pathId) override
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ struct npc_ranger_lilatha : public npc_escortAI
|
|||
if (quest->GetQuestId() == QUEST_ESCAPE_FROM_THE_CATACOMBS)
|
||||
{
|
||||
me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
npc_escortAI::Start(true, false, player->GetGUID());
|
||||
npc_escortAI::Start(true, player->GetGUID());
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -132,7 +132,7 @@ public:
|
|||
if (GameObject* go = me->FindNearestGameObject(GO_RINJI_CAGE, INTERACTION_DISTANCE))
|
||||
go->UseDoorOrButton();
|
||||
|
||||
npc_escortAI::Start(false, false, player->GetGUID(), quest);
|
||||
npc_escortAI::Start(false, player->GetGUID(), quest);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -156,7 +156,7 @@ public:
|
|||
case 17:
|
||||
Talk(SAY_RIN_COMPLETE, player);
|
||||
player->GroupEventHappens(QUEST_RINJI_TRAPPED, me);
|
||||
SetRun();
|
||||
SetRun(true);
|
||||
postEventCount = 1;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_MISSING_IN_ACTION)
|
||||
{
|
||||
Talk(SAY_CORPORAL_1, player);
|
||||
npc_escortAI::Start(true, false, player->GetGUID(), quest);
|
||||
npc_escortAI::Start(true, player->GetGUID(), quest);
|
||||
me->SetImmuneToNPC(false);
|
||||
me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_ACTIVE);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ public:
|
|||
creature->AI()->Talk(SAY_QUESTACCEPT, player);
|
||||
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_deathstalker_erland::npc_deathstalker_erlandAI, creature->AI()))
|
||||
pEscortAI->Start(true, false, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -406,7 +406,7 @@ public:
|
|||
{
|
||||
if (Player* player = GetPlayerForEscort())
|
||||
{
|
||||
CAST_AI(npc_lord_gregor_lescovar::npc_lord_gregor_lescovarAI, pLescovar->AI())->Start(false, false, player->GetGUID());
|
||||
CAST_AI(npc_lord_gregor_lescovar::npc_lord_gregor_lescovarAI, pLescovar->AI())->Start(false, player->GetGUID());
|
||||
CAST_AI(npc_lord_gregor_lescovar::npc_lord_gregor_lescovarAI, pLescovar->AI())->SetMaxPlayerDistance(200.0f);
|
||||
}
|
||||
}
|
||||
|
|
@ -448,7 +448,7 @@ public:
|
|||
{
|
||||
if (Creature* pSpybot = creature->FindNearestCreature(NPC_TYRION_SPYBOT, 5.0f, true))
|
||||
{
|
||||
CAST_AI(npc_tyrion_spybot::npc_tyrion_spybotAI, pSpybot->AI())->Start(false, false, player->GetGUID());
|
||||
CAST_AI(npc_tyrion_spybot::npc_tyrion_spybotAI, pSpybot->AI())->Start(false, player->GetGUID());
|
||||
CAST_AI(npc_tyrion_spybot::npc_tyrion_spybotAI, pSpybot->AI())->SetMaxPlayerDistance(200.0f);
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ public:
|
|||
{
|
||||
summoned->SetDisableGravity(true);
|
||||
float speed = summoned->GetDistance(summoned->GetPositionX(), summoned->GetPositionY(), me->GetPositionZ() + 15.0f) / (1000.0f * 0.001f);
|
||||
summoned->MonsterMoveWithSpeed(summoned->GetPositionX(), summoned->GetPositionY(), me->GetPositionZ() + 15.0f, speed);
|
||||
summoned->GetMotionMaster()->MovePoint(0, summoned->GetPositionX(), summoned->GetPositionY(), me->GetPositionZ() + 15.0f, FORCED_MOVEMENT_NONE, speed);
|
||||
summoned->CastSpell(summoned, SPELL_RIBBON_OF_SOULS, false);
|
||||
}
|
||||
}
|
||||
|
|
@ -270,8 +270,7 @@ public:
|
|||
if (EventMoveTimer <= diff)
|
||||
{
|
||||
me->SetDisableGravity(true);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), HIGHBORNE_LOC_Y_NEW, me->GetDistance(me->GetPositionX(), me->GetPositionY(), HIGHBORNE_LOC_Y_NEW) / (5000 * 0.001f));
|
||||
me->SetPosition(me->GetPositionX(), me->GetPositionY(), HIGHBORNE_LOC_Y_NEW, me->GetOrientation());
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), HIGHBORNE_LOC_Y_NEW, FORCED_MOVEMENT_NONE, me->GetDistance(me->GetPositionX(), me->GetPositionY(), HIGHBORNE_LOC_Y_NEW) / (5000 * 0.001f));
|
||||
EventMove = false;
|
||||
}
|
||||
else EventMoveTimer -= diff;
|
||||
|
|
@ -917,7 +916,8 @@ public:
|
|||
|
||||
if (auto ai = CAST_AI(npc_varian_wrynn::npc_varian_wrynnAI, creature->AI()))
|
||||
{
|
||||
ai->Start(true, true, player->GetGUID());
|
||||
creature->SetWalk(false);
|
||||
ai->Start(true, player->GetGUID());
|
||||
if (Creature* jaina = GetClosestCreatureWithEntry(creature, NPC_JAINA, 50.0f))
|
||||
ai->jainaGUID = jaina->GetGUID();
|
||||
else
|
||||
|
|
@ -1218,27 +1218,27 @@ public:
|
|||
{
|
||||
case 0:
|
||||
if (Unit* temp = me->SummonCreature(NPC_DOCTOR, AllianceSpawn[4].x - rand32() % 5, AllianceSpawn[4].y - rand32() % 5, AllianceSpawn[4].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 1:
|
||||
if (Unit* temp = me->SummonCreature(NPC_CHEMIST, AllianceSpawn[4].x - rand32() % 5, AllianceSpawn[4].y - rand32() % 5, AllianceSpawn[4].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 2:
|
||||
if (Unit* temp = me->SummonCreature(NPC_BETRAYER, AllianceSpawn[4].x - rand32() % 5, AllianceSpawn[4].y - rand32() % 5, AllianceSpawn[4].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 3:
|
||||
if (Unit* temp = me->SummonCreature(NPC_DOCTOR, AllianceSpawn[5].x - rand32() % 5, AllianceSpawn[5].y - rand32() % 5, AllianceSpawn[5].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 4:
|
||||
if (Unit* temp = me->SummonCreature(NPC_CHEMIST, AllianceSpawn[5].x - rand32() % 5, AllianceSpawn[5].y - rand32() % 5, AllianceSpawn[5].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 5:
|
||||
if (Unit* temp = me->SummonCreature(NPC_BETRAYER, AllianceSpawn[5].x - rand32() % 5, AllianceSpawn[5].y - rand32() % 5, AllianceSpawn[5].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -1246,7 +1246,7 @@ public:
|
|||
case 5:
|
||||
for (uint8 i = 0; i < WAVE_MAXCOUNT; ++i)
|
||||
if (Unit* temp = me->SummonCreature(NPC_GUARDIAN, AllianceSpawn[6].x - rand32() % 5, AllianceSpawn[6].y - rand32() % 5, AllianceSpawn[6].z, TEMPSUMMON_DEAD_DESPAWN))
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), false);
|
||||
temp->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case 6:
|
||||
if (Unit* temp = me->SummonCreature(NPC_BLIGHTWORM, AllianceSpawn[7].x, AllianceSpawn[7].y, AllianceSpawn[7].z, TEMPSUMMON_MANUAL_DESPAWN))
|
||||
|
|
@ -1614,7 +1614,7 @@ public:
|
|||
break;
|
||||
case 22:
|
||||
Talk(WRYNN_SAY_SEWERS_4);
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
if (Creature* jaina = ObjectAccessor::GetCreature(*me, jainaGUID))
|
||||
{
|
||||
jaina->GetMotionMaster()->Clear();
|
||||
|
|
@ -1665,7 +1665,7 @@ public:
|
|||
JumpToNextStep(3 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 31:
|
||||
SetRun(true);
|
||||
me->SetWalk(false);
|
||||
if (Creature* jaina = ObjectAccessor::GetCreature(*me, jainaGUID))
|
||||
jaina->GetMotionMaster()->MoveFollow(me, 1, 0);
|
||||
SetEscortPaused(false);
|
||||
|
|
@ -1727,7 +1727,7 @@ public:
|
|||
if (Creature* jaina = ObjectAccessor::GetCreature(*me, jainaGUID))
|
||||
{
|
||||
jaina->GetMotionMaster()->Clear();
|
||||
jaina->GetMotionMaster()->MovePoint(0, AllianceWP[7].x, AllianceWP[7].y, AllianceWP[7].z, false);
|
||||
jaina->GetMotionMaster()->MovePoint(0, AllianceWP[7].x, AllianceWP[7].y, AllianceWP[7].z, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
}
|
||||
JumpToNextStep(5 * IN_MILLISECONDS);
|
||||
break;
|
||||
|
|
@ -1789,7 +1789,7 @@ public:
|
|||
break;
|
||||
case 54:
|
||||
Talk(WRYNN_SAY_APO_7);
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(4 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 55:
|
||||
|
|
@ -1845,7 +1845,7 @@ public:
|
|||
JumpToNextStep(1.5 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 65:
|
||||
SetRun(true);
|
||||
me->SetWalk(false);
|
||||
SetEscortPaused(false);
|
||||
JumpToNextStep(0.25 * IN_MILLISECONDS);
|
||||
break;
|
||||
|
|
@ -2236,7 +2236,8 @@ public:
|
|||
if (Creature* sylvannas = GetClosestCreatureWithEntry(creature, NPC_SYLVANAS, 50.0f))
|
||||
{
|
||||
thrall_ai->sylvanasfollowGUID = sylvannas->GetGUID();
|
||||
thrall_ai->Start(true, true, player->GetGUID());
|
||||
creature->SetWalk(false);
|
||||
thrall_ai->Start(true, player->GetGUID());
|
||||
thrall_ai->SetDespawnAtEnd(false);
|
||||
thrall_ai->SetDespawnAtFar(false);
|
||||
}
|
||||
|
|
@ -2477,7 +2478,7 @@ public:
|
|||
for (std::list<Creature*>::iterator itr = ThroneList.begin(); itr != ThroneList.end(); itr++)
|
||||
(*itr)->DespawnOrUnsummon();
|
||||
SetEscortPaused(false);
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
|
@ -2972,7 +2973,7 @@ public:
|
|||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
JumpToNextStep(0);
|
||||
SetRun(true);
|
||||
me->SetWalk(false);
|
||||
if (Creature* sylvanas = ObjectAccessor::GetCreature(*me, sylvanasfollowGUID))
|
||||
{
|
||||
sylvanas->GetMotionMaster()->MovePath(NPC_SYLVANAS * 100, false);
|
||||
|
|
@ -3005,7 +3006,7 @@ public:
|
|||
for (std::list<Creature*>::iterator itr = PlagueList.begin(); itr != PlagueList.end(); itr++)
|
||||
(*itr)->DespawnOrUnsummon();
|
||||
SetEscortPaused(false);
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
if (Creature* sylvanas = ObjectAccessor::GetCreature(*me, sylvanasfollowGUID))
|
||||
sylvanas->GetMotionMaster()->MovePath(NPC_SYLVANAS * 1000, false);
|
||||
JumpToNextStep(3 * IN_MILLISECONDS);
|
||||
|
|
@ -3077,7 +3078,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(true);
|
||||
me->SetWalk(false);
|
||||
Talk(THRALL_SAY_COURTYARD_4);
|
||||
UpdateWorldState(me->GetMap(), WORLD_STATE_BATTLE_FOR_UNDERCITY_START_H, 0);
|
||||
UpdateWorldState(me->GetMap(), WORLD_STATE_BATTLE_FOR_UNDERCITY_COURTYARD_FIGHT_H, 1);
|
||||
|
|
@ -3182,7 +3183,7 @@ public:
|
|||
SpawnWave(6);
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
}
|
||||
|
|
@ -3226,7 +3227,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
// Top of Undercity Discussion
|
||||
|
|
@ -3266,7 +3267,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 63:
|
||||
|
|
@ -3284,7 +3285,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 67:
|
||||
|
|
@ -3299,7 +3300,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
// KHANOK - Valimathtas Intro
|
||||
|
|
@ -3475,7 +3476,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 109:
|
||||
|
|
@ -3491,7 +3492,7 @@ public:
|
|||
FollowThrall();
|
||||
SetEscortPaused(false);
|
||||
bStepping = false;
|
||||
SetRun(true);
|
||||
me->SetWalk(false);
|
||||
JumpToNextStep(0 * IN_MILLISECONDS);
|
||||
break;
|
||||
case 112:
|
||||
|
|
@ -3662,7 +3663,7 @@ public:
|
|||
case 143:
|
||||
if (Creature* sylvanas = ObjectAccessor::GetCreature(*me, sylvanasfollowGUID))
|
||||
{
|
||||
sylvanas->GetMotionMaster()->MovePoint(0, 1289.48f, 314.33f, -57.32f, true);
|
||||
sylvanas->GetMotionMaster()->MovePoint(0, 1289.48f, 314.33f, -57.32f);
|
||||
sylvanas->CastSpell(sylvanas, SPELL_LEAP_TO_PLATFORM);
|
||||
}
|
||||
JumpToNextStep(10 * IN_MILLISECONDS);
|
||||
|
|
@ -3706,7 +3707,7 @@ public:
|
|||
wrynn->SetImmuneToAll(true);
|
||||
wrynn->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_READY2H);
|
||||
wrynn->SetReactState(REACT_PASSIVE);
|
||||
wrynn->GetMotionMaster()->MovePoint(0, 1302.543f, 359.472f, -67.295f, true);
|
||||
wrynn->GetMotionMaster()->MovePoint(0, 1302.543f, 359.472f, -67.295f);
|
||||
}
|
||||
if (Creature* jaina = me->SummonCreature(NPC_JAINA, 1308.862f, 381.809f, -66.044243f, TEMPSUMMON_MANUAL_DESPAWN))
|
||||
{
|
||||
|
|
@ -3807,7 +3808,7 @@ public:
|
|||
{
|
||||
SaurfangGUID = saurfang->GetGUID();
|
||||
saurfang->SetWalk(true);
|
||||
saurfang->GetMotionMaster()->MovePoint(0, 1300.862f, 353.670f, -66.187f, true);
|
||||
saurfang->GetMotionMaster()->MovePoint(0, 1300.862f, 353.670f, -66.187f);
|
||||
}
|
||||
JumpToNextStep(7 * IN_MILLISECONDS);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -56,9 +56,9 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_TOME_VALOR)
|
||||
{
|
||||
creature->AI()->Talk(SAY_DS_START);
|
||||
|
||||
creature->SetWalk(false);
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_daphne_stilwell::npc_daphne_stilwellAI, creature->AI()))
|
||||
pEscortAI->Start(true, true, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ public:
|
|||
case 2:
|
||||
if (me->HasStealthAura())
|
||||
me->RemoveAurasByType(SPELL_AURA_MOD_STEALTH);
|
||||
SetRun();
|
||||
me->SetWalk(false);
|
||||
me->SetFaction(FACTION_ENEMY);
|
||||
break;
|
||||
}
|
||||
|
|
@ -109,7 +109,7 @@ public:
|
|||
me->GetThreatMgr().ClearAllThreat();
|
||||
me->CombatStop(true);
|
||||
|
||||
SetRun(false);
|
||||
me->SetWalk(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -138,7 +138,7 @@ public:
|
|||
pSlim->CastSpell(pSlim, SPELL_STEALTH, true);
|
||||
|
||||
if (npc_tapoke_slim_jahn::npc_tapoke_slim_jahnAI* pEscortAI = CAST_AI(npc_tapoke_slim_jahn::npc_tapoke_slim_jahnAI, pSlim->AI()))
|
||||
pEscortAI->Start(false, false, player->GetGUID(), quest);
|
||||
pEscortAI->Start(false, player->GetGUID(), quest);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -678,19 +678,19 @@ public:
|
|||
me->SummonCreature(NPC_JAINA, EventPos[EVENT_SRC_JAINA], TEMPSUMMON_DEAD_DESPAWN, 180000);
|
||||
if (Creature* uther = me->SummonCreature(NPC_UTHER, EventPos[EVENT_SRC_UTHER], TEMPSUMMON_DEAD_DESPAWN, 180000))
|
||||
{
|
||||
uther->GetMotionMaster()->MovePoint(0, EventPos[EVENT_DST_UTHER], false);
|
||||
uther->GetMotionMaster()->MovePoint(0, EventPos[EVENT_DST_UTHER], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
uther->SetTarget(me->GetGUID());
|
||||
me->SetTarget(uther->GetGUID());
|
||||
}
|
||||
for (int i = 0; i < 3; ++i)
|
||||
if (Creature* horse = me->SummonCreature(NPC_HORSE_ESCORT, EventPos[EVENT_SRC_HORSE1 + i], TEMPSUMMON_DEAD_DESPAWN, 180000))
|
||||
horse->GetMotionMaster()->MovePoint(0, EventPos[EVENT_DST_HORSE1 + i], false);
|
||||
horse->GetMotionMaster()->MovePoint(0, EventPos[EVENT_DST_HORSE1 + i], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
ScheduleNextEvent(currentEvent, 4s);
|
||||
break;
|
||||
case EVENT_ACTION_PHASE1+1:
|
||||
// Start Event
|
||||
Start(true, false);
|
||||
Start(true);
|
||||
SetDespawnAtEnd(false);
|
||||
SetDespawnAtFar(false);
|
||||
|
||||
|
|
@ -782,7 +782,7 @@ public:
|
|||
{
|
||||
Creature* summon = ObjectAccessor::GetCreature(*me, *i);
|
||||
if (summon && summon->GetEntry() == NPC_HORSE_ESCORT)
|
||||
summon->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], false);
|
||||
summon->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
|
||||
ScheduleNextEvent(currentEvent, 1s);
|
||||
|
|
@ -792,7 +792,7 @@ public:
|
|||
{
|
||||
uther->SetTarget();
|
||||
uther->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
uther->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], false);
|
||||
uther->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
ScheduleNextEvent(currentEvent, 1s);
|
||||
break;
|
||||
|
|
@ -801,7 +801,7 @@ public:
|
|||
{
|
||||
jaina->SetTarget();
|
||||
jaina->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
jaina->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], false);
|
||||
jaina->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
Talk(SAY_PHASE116);
|
||||
ScheduleNextEvent(currentEvent, 2s);
|
||||
|
|
@ -819,7 +819,7 @@ public:
|
|||
if (Creature* jaina = GetEventNpc(NPC_JAINA))
|
||||
{
|
||||
jaina->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
jaina->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], false);
|
||||
jaina->GetMotionMaster()->MovePoint(0, EventPos[EVENT_POS_RETREAT], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
summons.DespawnEntry(NPC_HORSE_ESCORT);
|
||||
ScheduleNextEvent(currentEvent, 4s);
|
||||
|
|
@ -1242,7 +1242,8 @@ void npc_arthas::npc_arthasAI::JustEngagedWith(Unit* /*who*/)
|
|||
|
||||
void npc_arthas::npc_arthasAI::ReorderInstance(uint32 data)
|
||||
{
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
SetEscortPaused(true);
|
||||
SetDespawnAtEnd(false);
|
||||
|
||||
|
|
|
|||
|
|
@ -566,7 +566,8 @@ public:
|
|||
me->SummonCreature(NPC_DURNHOLDE_MAGE, 2108.4856f, 189.93457f, 66.30494f, 2.6878f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30 * IN_MILLISECONDS);
|
||||
break;
|
||||
case EVENT_START_WP:
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
SetDespawnAtEnd(false);
|
||||
break;
|
||||
case EVENT_SET_FACING:
|
||||
|
|
@ -809,7 +810,7 @@ public:
|
|||
if (Creature* epoch = summons.GetCreatureWithEntry(NPC_EPOCH_HUNTER))
|
||||
{
|
||||
epoch->SetImmuneToAll(false);
|
||||
epoch->GetMotionMaster()->MovePoint(0, *me, false, true);
|
||||
epoch->GetMotionMaster()->MovePoint(0, *me, FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
}
|
||||
break;
|
||||
case EVENT_THRALL_FACE_TARETHA:
|
||||
|
|
@ -922,7 +923,8 @@ public:
|
|||
|
||||
void ReorderInstance(uint32 data)
|
||||
{
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
SetEscortPaused(true);
|
||||
SetDespawnAtEnd(false);
|
||||
|
||||
|
|
@ -1008,7 +1010,8 @@ public:
|
|||
{
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
me->RemoveAllAuras();
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 waypointId) override
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ struct npc_medivh_bm : public ScriptedAI
|
|||
summon->CastSpell(summon, SPELL_BLACK_CRYSTAL, true);
|
||||
Movement::MoveSplineInit init(summon);
|
||||
init.MovebyPath(_groundArray);
|
||||
init.SetCyclic();
|
||||
init.SetCyclic(); // TODO: Add support for cyclic paths in motion master
|
||||
init.Launch();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -209,7 +209,8 @@ struct npc_general_andorov : public npc_escortAI
|
|||
_initialAttackTimer = 5 * IN_MILLISECONDS;
|
||||
_paused = false;
|
||||
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
|
||||
me->SetImmuneToNPC(true);
|
||||
me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE);
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@ public:
|
|||
{
|
||||
Talk(SAY_MUG_START1);
|
||||
me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
npc_escortAI::Start(true, false, player->GetGUID());
|
||||
npc_escortAI::Start(true, player->GetGUID());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -289,7 +289,7 @@ public:
|
|||
case EVENT_START_ESCORT:
|
||||
if (Player* player = ObjectAccessor::GetPlayer(*me, _player))
|
||||
{
|
||||
npc_escortAI::Start(true, false, player->GetGUID());
|
||||
npc_escortAI::Start(true, player->GetGUID());
|
||||
}
|
||||
_events.ScheduleEvent(EVENT_STAND, 2s);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -397,7 +397,7 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_ABSENT_MINDED_PT2)
|
||||
{
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_prospector_remtravel::npc_prospector_remtravelAI, creature->AI()))
|
||||
pEscortAI->Start(false, false, player->GetGUID());
|
||||
pEscortAI->Start(false, player->GetGUID());
|
||||
|
||||
creature->SetFaction(FACTION_ESCORTEE_A_NEUTRAL_PASSIVE);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -396,7 +396,8 @@ public:
|
|||
case EVENT_RESTART_ESCORT:
|
||||
CheckCaravan();
|
||||
SetDespawnAtEnd(false);
|
||||
Start(true, true, ObjectGuid::Empty, 0, false, false, true);
|
||||
SetRun(true);
|
||||
Start(true, ObjectGuid::Empty, 0, false, false, true);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -384,7 +384,7 @@ public:
|
|||
AddWaypoint(i, Clintar_spirit_WP[i][0], Clintar_spirit_WP[i][1], Clintar_spirit_WP[i][2], (uint32)Clintar_spirit_WP[i][4]);
|
||||
}
|
||||
PlayerGUID = player->GetGUID();
|
||||
Start(true, false, PlayerGUID);
|
||||
Start(true, PlayerGUID);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -137,7 +137,7 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_PROTECT_KAYA)
|
||||
{
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_kaya_flathoof::npc_kaya_flathoofAI, creature->AI()))
|
||||
pEscortAI->Start(true, false, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
|
||||
creature->AI()->Talk(SAY_START);
|
||||
creature->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
|
|
|
|||
|
|
@ -260,7 +260,7 @@ public:
|
|||
float Radius = 10.0f;
|
||||
if (me->IsWithinDistInMap(who, Radius))
|
||||
{
|
||||
Start(false, false, who->GetGUID());
|
||||
Start(false, who->GetGUID());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ public:
|
|||
creature->AI()->Talk(SAY_GIL_START, player);
|
||||
|
||||
if (npc_giltharesAI* pEscortAI = CAST_AI(npc_gilthares::npc_giltharesAI, creature->AI()))
|
||||
pEscortAI->Start(false, false, player->GetGUID(), quest);
|
||||
pEscortAI->Start(false, player->GetGUID(), quest);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -528,7 +528,7 @@ public:
|
|||
break;
|
||||
case 18:
|
||||
Talk(SAY_PROGRESS_1, player);
|
||||
SetRun();
|
||||
SetRun(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -594,7 +594,7 @@ public:
|
|||
creature->SetFaction(FACTION_RATCHET);
|
||||
creature->AI()->Talk(SAY_START);
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_wizzlecrank_shredder::npc_wizzlecrank_shredderAI, creature->AI()))
|
||||
pEscortAI->Start(true, false, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ public:
|
|||
creature->SetFaction(FACTION_ESCORTEE_H_NEUTRAL_ACTIVE); //guessed
|
||||
|
||||
if (npc_lakota_windsongAI* pEscortAI = CAST_AI(npc_lakota_windsong::npc_lakota_windsongAI, creature->AI()))
|
||||
pEscortAI->Start(false, false, player->GetGUID(), quest);
|
||||
pEscortAI->Start(false, player->GetGUID(), quest);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -148,7 +148,7 @@ public:
|
|||
creature->SetFaction(FACTION_ESCORTEE_H_NEUTRAL_ACTIVE); // guessed
|
||||
|
||||
if (npc_paoka_swiftmountainAI* pEscortAI = CAST_AI(npc_paoka_swiftmountain::npc_paoka_swiftmountainAI, creature->AI()))
|
||||
pEscortAI->Start(false, false, player->GetGUID(), quest);
|
||||
pEscortAI->Start(false, player->GetGUID(), quest);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ public:
|
|||
{
|
||||
if (quest->GetQuestId() == QUEST_CHASING_AME)
|
||||
{
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(false, false, player->GetGUID());
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(false, player->GetGUID());
|
||||
creature->AI()->Talk(SAY_READY, player);
|
||||
creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
|
||||
// Change faction so mobs attack
|
||||
|
|
|
|||
|
|
@ -286,7 +286,7 @@ public:
|
|||
creature->SetFaction(FACTION_ESCORT_A_NEUTRAL_PASSIVE);
|
||||
|
||||
if (npc_ranshallaAI* escortAI = dynamic_cast<npc_ranshallaAI*>(creature->AI()))
|
||||
escortAI->Start(false, false, player->GetGUID(), quest);
|
||||
escortAI->Start(false, player->GetGUID(), quest);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -258,7 +258,7 @@ public:
|
|||
{
|
||||
if (summon->GetEntry() != me->GetEntry())
|
||||
{
|
||||
summon->GetMotionMaster()->MovePoint(0, *me, false);
|
||||
summon->GetMotionMaster()->MovePoint(0, *me, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
summon->GetMotionMaster()->MoveFollow(me, 0.1f, 0.0f + M_PI * 0.3f * summons.size());
|
||||
}
|
||||
summons.Summon(summon);
|
||||
|
|
|
|||
|
|
@ -173,7 +173,7 @@ struct boss_jedoga_shadowseeker : public BossAI
|
|||
me->AddUnitState(UNIT_STATE_NO_ENVIRONMENT_UPD);
|
||||
me->SetDisableGravity(true);
|
||||
me->SetHover(true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_INITIAL, JedogaPosition[0], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_INITIAL, JedogaPosition[0], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
_Reset();
|
||||
events.SetPhase(PHASE_NORMAL);
|
||||
|
|
@ -247,7 +247,7 @@ struct boss_jedoga_shadowseeker : public BossAI
|
|||
DespawnOOCSummons();
|
||||
DoCastSelf(SPELL_HOVER_FALL);
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
if (!combatSummonsSummoned)
|
||||
{
|
||||
|
|
@ -397,7 +397,7 @@ struct boss_jedoga_shadowseeker : public BossAI
|
|||
volunteerWork = false;
|
||||
me->GetMotionMaster()->Clear();
|
||||
DoCastSelf(SPELL_HOVER_FALL);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
@ -504,7 +504,7 @@ struct boss_jedoga_shadowseeker : public BossAI
|
|||
summons.DespawnEntry(NPC_JEDOGA_CONTROLLER);
|
||||
DoCastSelf(SPELL_HOVER_FALL);
|
||||
me->GetMotionMaster()->Clear();
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DOWN, JedogaPosition[1], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
break;
|
||||
}
|
||||
case EVENT_JEDGA_START_RITUAL:
|
||||
|
|
@ -663,7 +663,7 @@ struct npc_twilight_volunteer : public ScriptedAI
|
|||
me->GetMotionMaster()->Clear();
|
||||
me->SetHomePosition(JedogaPosition[2]);
|
||||
me->SetWalk(true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_RITUAL, JedogaPosition[2], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_RITUAL, JedogaPosition[2], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
if (Creature* jedoga = pInstance->GetCreature(DATA_JEDOGA_SHADOWSEEKER))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -210,7 +210,8 @@ public:
|
|||
{
|
||||
_lavaGoutCount = 0;
|
||||
AddWaypoints();
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
}
|
||||
|
||||
void JustEngagedWith(Unit* /*who*/) override
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ public:
|
|||
me->SetReactState(REACT_PASSIVE);
|
||||
me->AttackStop();
|
||||
me->SetDisableGravity(true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_TAKEOFF, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 6.0f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_TAKEOFF, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 6.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
events.ScheduleEvent(EVENT_FLIGHT, 50s);
|
||||
events.DelayEvents(15s);
|
||||
events.ScheduleEvent(EVENT_AIR_MOVEMENT, 2s);
|
||||
|
|
@ -163,10 +163,10 @@ public:
|
|||
events.ScheduleEvent(EVENT_FLAME_BREATH, 20s, 30s);
|
||||
break;
|
||||
case EVENT_AIR_MOVEMENT:
|
||||
me->GetMotionMaster()->MovePoint(POINT_FLIGHT, 3155.51f, 683.844f, 95.0f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_FLIGHT, 3155.51f, 683.844f, 95.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case EVENT_LAND_BACK:
|
||||
me->GetMotionMaster()->MovePoint(POINT_LAND, 3151.07f, 636.443f, 80.0f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_LAND, 3151.07f, 636.443f, 80.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
break;
|
||||
case EVENT_LAND_GROUND:
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
|
|
|
|||
|
|
@ -607,7 +607,8 @@ public:
|
|||
break;
|
||||
}
|
||||
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
uiWaypoint = uiType;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -339,7 +339,8 @@ public:
|
|||
|
||||
void Reset() override
|
||||
{
|
||||
Start(false, true, ObjectGuid::Empty, nullptr);
|
||||
me->SetWalk(false);
|
||||
Start(false, ObjectGuid::Empty, nullptr);
|
||||
SetDespawnAtEnd(true);
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->SetImmuneToAll(true);
|
||||
|
|
|
|||
|
|
@ -549,7 +549,8 @@ public:
|
|||
return;
|
||||
}
|
||||
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
}
|
||||
|
||||
void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override
|
||||
|
|
|
|||
|
|
@ -571,7 +571,7 @@ public:
|
|||
pInstance->HandleGameObject(pInstance->GetGuidData(GO_ARTHAS_DOOR), true);
|
||||
pLichKing->SetVisible(true);
|
||||
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveMidlelThronePos, false);
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveMidlelThronePos, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -618,7 +618,7 @@ public:
|
|||
if (Creature* pLichKing = ObjectAccessor::GetCreature(*me, pInstance->GetGuidData(NPC_LICH_KING_EVENT)))
|
||||
{
|
||||
pLichKing->SetVisible(true);
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveThronePos, false);
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveThronePos, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_INTRO_LK_2_1, 1s);
|
||||
break;
|
||||
|
|
@ -709,7 +709,7 @@ public:
|
|||
case EVENT_INTRO_LK_5_2:
|
||||
if (Creature* pLichKing = ObjectAccessor::GetCreature(*me, pInstance->GetGuidData(NPC_LICH_KING_EVENT)))
|
||||
{
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveAwayPos, false);
|
||||
pLichKing->GetMotionMaster()->MovePoint(0, LichKingMoveAwayPos, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
@ -763,11 +763,11 @@ public:
|
|||
{
|
||||
Talk(SAY_SYLVANAS_INTRO_END);
|
||||
me->HandleEmoteCommand(EMOTE_ONESHOT_EXCLAMATION);
|
||||
me->GetMotionMaster()->MovePoint(0, LichKingMoveAwayPos, false);
|
||||
me->GetMotionMaster()->MovePoint(0, LichKingMoveAwayPos, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
if (Creature* pLoralen = pInstance->instance->GetCreature(pInstance->GetGuidData(NPC_DARK_RANGER_LORALEN)))
|
||||
{
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk1, false);
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk1, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_INTRO_LK_10, 1s + 500ms);
|
||||
break;
|
||||
|
|
@ -775,7 +775,7 @@ public:
|
|||
case EVENT_INTRO_LK_10:
|
||||
if (Creature* pLoralen = pInstance->instance->GetCreature(pInstance->GetGuidData(NPC_DARK_RANGER_LORALEN)))
|
||||
{
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk2, false);
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk2, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
|
||||
}
|
||||
events.ScheduleEvent(EVENT_INTRO_LK_11, 2s);
|
||||
|
|
@ -784,7 +784,7 @@ public:
|
|||
case EVENT_INTRO_LK_11:
|
||||
if (Creature* pLoralen = pInstance->instance->GetCreature(pInstance->GetGuidData(NPC_DARK_RANGER_LORALEN)))
|
||||
{
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk3, false);
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLk3, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_INTRO_LK_12, 5s + 500ms);
|
||||
break;
|
||||
|
|
@ -796,7 +796,7 @@ public:
|
|||
}
|
||||
if (Creature* pLoralen = pInstance->instance->GetCreature(pInstance->GetGuidData(NPC_DARK_RANGER_LORALEN)))
|
||||
{
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLkFinal, false);
|
||||
pLoralen->GetMotionMaster()->MovePoint(0, LoralenFollowLkFinal, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_INTRO_LK_13, 2s);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -674,14 +674,14 @@ public:
|
|||
switch (events.ExecuteEvent())
|
||||
{
|
||||
case 1:
|
||||
me->GetMotionMaster()->MovePoint(2, PTSTyrannusWaitPos1, false);
|
||||
me->GetMotionMaster()->MovePoint(2, PTSTyrannusWaitPos1, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
break;
|
||||
case 2:
|
||||
me->SetFacingTo(PTSTyrannusWaitPos1.GetOrientation());
|
||||
me->setActive(false);
|
||||
break;
|
||||
case 3:
|
||||
me->GetMotionMaster()->MovePoint(3, PTSTyrannusWaitPos2, false);
|
||||
me->GetMotionMaster()->MovePoint(3, PTSTyrannusWaitPos2, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
break;
|
||||
case 4:
|
||||
me->SetFacingTo(PTSTyrannusWaitPos2.GetOrientation());
|
||||
|
|
@ -690,7 +690,7 @@ public:
|
|||
me->GetMotionMaster()->MoveTakeoff(10, me->GetPositionX() + 2.0f * cos(me->GetOrientation()), me->GetPositionY() + 2.0f * std::sin(me->GetOrientation()), me->GetPositionZ() + 30.0f, 7.0f);
|
||||
break;
|
||||
case 6:
|
||||
me->GetMotionMaster()->MovePoint(4, PTSTyrannusWaitPos3, false);
|
||||
me->GetMotionMaster()->MovePoint(4, PTSTyrannusWaitPos3, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
break;
|
||||
case 30:
|
||||
{
|
||||
|
|
@ -1355,7 +1355,7 @@ public:
|
|||
}
|
||||
}
|
||||
if (minDist < 200.0f * 200.0f)
|
||||
_owner.GetMotionMaster()->MovePoint(0, slaveFreePos[pointId], true, false);
|
||||
_owner.GetMotionMaster()->MovePoint(0, slaveFreePos[pointId], FORCED_MOVEMENT_NONE, 0.f, true, false);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ public:
|
|||
void InitializeAI() override
|
||||
{
|
||||
BossAI::InitializeAI();
|
||||
me->GetMotionMaster()->MovePoint(POINT_START, 1638.55f, 919.76f, 104.95f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_START, 1638.55f, 919.76f, 104.95f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
me->SetHomePosition(1642.712f, 934.646f, 107.205f, 0.767f);
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -583,7 +583,7 @@ public:
|
|||
{
|
||||
me->RemoveAurasDueToSpell(SPELL_GRIP_OF_AGONY);
|
||||
me->SetDisableGravity(false);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), 539.2917f, 10.0f);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), 539.2917f, FORCED_MOVEMENT_NONE, 10.0f);
|
||||
for (std::list<Creature*>::iterator itr = _guardList.begin(); itr != _guardList.end(); ++itr)
|
||||
(*itr)->AI()->DoAction(ACTION_DESPAWN);
|
||||
|
||||
|
|
@ -845,7 +845,7 @@ public:
|
|||
{
|
||||
me->RemoveAurasDueToSpell(SPELL_GRIP_OF_AGONY);
|
||||
me->SetDisableGravity(false);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), 539.2917f, 10.0f);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), 539.2917f, FORCED_MOVEMENT_NONE, 10.0f);
|
||||
for (std::list<Creature*>::iterator itr = _guardList.begin(); itr != _guardList.end(); ++itr)
|
||||
(*itr)->AI()->DoAction(ACTION_DESPAWN);
|
||||
|
||||
|
|
|
|||
|
|
@ -503,7 +503,7 @@ public:
|
|||
float x, y, z, o;
|
||||
_dest.GetPosition(x, y, z, o);
|
||||
_owner->GetTransport()->CalculatePassengerPosition(x, y, z, &o);
|
||||
_owner->GetMotionMaster()->MovePoint(EVENT_CHARGE_PREPATH, x, y, z, false);
|
||||
_owner->GetMotionMaster()->MovePoint(EVENT_CHARGE_PREPATH, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -915,7 +915,7 @@ public:
|
|||
{
|
||||
float x, y, z, o;
|
||||
me->GetHomePosition(x, y, z, o);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
@ -1072,7 +1072,7 @@ public:
|
|||
{
|
||||
float x, y, z, o;
|
||||
me->GetHomePosition(x, y, z, o);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1251,7 +1251,7 @@ public:
|
|||
{
|
||||
float x, y, z, o;
|
||||
me->GetHomePosition(x, y, z, o);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
@ -1411,7 +1411,7 @@ public:
|
|||
{
|
||||
float x, y, z, o;
|
||||
me->GetHomePosition(x, y, z, o);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1518,7 +1518,7 @@ struct gunship_npc_AI : public ScriptedAI
|
|||
me->SetTransportHomePosition(Slot->TargetPosition);
|
||||
me->GetTransport()->CalculatePassengerPosition(x, y, z, &o);
|
||||
me->SetHomePosition(x, y, z, o);
|
||||
me->GetMotionMaster()->MovePoint(EVENT_CHARGE_PREPATH, x, y, z, false);
|
||||
me->GetMotionMaster()->MovePoint(EVENT_CHARGE_PREPATH, x, y, z, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2565,7 +2565,7 @@ public:
|
|||
me->AddUnitState(UNIT_STATE_NO_ENVIRONMENT_UPD);
|
||||
me->SetCanFly(false);
|
||||
me->SetDisableGravity(false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DROP_PLAYER, _destPoint, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DROP_PLAYER, _destPoint, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
me->SetDisableGravity(true, true);
|
||||
me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -934,7 +934,8 @@ public:
|
|||
case EVENT_START_PATHING:
|
||||
me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->SetImmuneToAll(false);
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
break;
|
||||
case EVENT_SCOURGE_STRIKE:
|
||||
DoCastVictim(SPELL_SCOURGE_STRIKE);
|
||||
|
|
@ -3347,7 +3348,7 @@ public:
|
|||
if (Creature* broodling = me->SummonCreature(NPC_NERUBAR_BROODLING, me->GetPositionX() + cos(o) * dist, me->GetPositionY() + std::sin(o) * dist, 250.0f, Position::NormalizeOrientation(o - M_PI)))
|
||||
{
|
||||
broodling->CastSpell(broodling, SPELL_WEB_BEAM2, false);
|
||||
broodling->GetMotionMaster()->MovePoint(POINT_ENTER_COMBAT, broodling->GetPositionX(), broodling->GetPositionY(), 213.03f, false);
|
||||
broodling->GetMotionMaster()->MovePoint(POINT_ENTER_COMBAT, broodling->GetPositionX(), broodling->GetPositionY(), 213.03f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -745,7 +745,7 @@ public:
|
|||
if (Creature* cr = me->SummonCreature(NPC_LIVING_POISON, entry.Start, TEMPSUMMON_TIMED_DESPAWN, entry.DespawnTime))
|
||||
{
|
||||
cr->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
cr->GetMotionMaster()->MovePoint(0, entry.End, false);
|
||||
cr->GetMotionMaster()->MovePoint(0, entry.End, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
|
||||
_events.Repeat(5s);
|
||||
|
|
|
|||
|
|
@ -521,7 +521,7 @@ public:
|
|||
}
|
||||
//pPlayer->ClearUnitState(UNIT_STATE_ONVEHICLE);
|
||||
|
||||
Movement::MoveSplineInit init(pPlayer);
|
||||
Movement::MoveSplineInit init(pPlayer); // TODO: has to be removed and handled with vehicle exit and vehicle enter code
|
||||
init.MoveTo(CenterPos.GetPositionX(), CenterPos.GetPositionY(), CenterPos.GetPositionZ());
|
||||
init.SetFacing(pPlayer->GetOrientation());
|
||||
init.SetTransportExit();
|
||||
|
|
@ -898,9 +898,9 @@ public:
|
|||
{
|
||||
Player* plr = pass->ToPlayer();
|
||||
float speed = plr->GetDistance(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()) / (1.0f * 0.001f);
|
||||
plr->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), speed);
|
||||
plr->SetDisableGravity(false); // packet only would lead to issues elsewhere
|
||||
plr->GetMotionMaster()->MoveCharge(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), speed);
|
||||
plr->RemoveAura(SPELL_FREEZE_ANIM);
|
||||
plr->SetDisableGravity(false, true);
|
||||
plr->SetGuidValue(PLAYER_FARSIGHT, ObjectGuid::Empty);
|
||||
|
||||
sScriptMgr->AnticheatSetCanFlybyServer(plr, false);
|
||||
|
|
@ -998,7 +998,7 @@ public:
|
|||
MoveTimer = 0;
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
me->DisableSpline();
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 0.05f, 7.0f);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 0.05f, FORCED_MOVEMENT_NONE, 7.0f);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -1013,8 +1013,7 @@ public:
|
|||
MoveTimer = 0;
|
||||
me->GetMotionMaster()->MoveIdle();
|
||||
me->DisableSpline();
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), CenterPos.GetPositionZ(), 100.0f);
|
||||
me->SetPosition(me->GetPositionX(), me->GetPositionY(), CenterPos.GetPositionZ(), me->GetOrientation());
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), CenterPos.GetPositionZ(), FORCED_MOVEMENT_NONE, 100.0f);
|
||||
me->ReplaceAllUnitFlags(UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_DISABLE_MOVE);
|
||||
me->RemoveAura(SPELL_POWER_SPARK_VISUAL);
|
||||
me->CastSpell(me, SPELL_POWER_SPARK_GROUND_BUFF, true);
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@ public:
|
|||
AddWaypoint(13, 1281.2f, -26.8f, 33.5f, 0);
|
||||
AddWaypoint(14, 1262, -26.9f, 33.5f, 0);
|
||||
|
||||
Start(true, false, ObjectGuid::Empty, nullptr, false, true);
|
||||
Start(true, ObjectGuid::Empty, nullptr, false, true);
|
||||
}
|
||||
|
||||
InstanceScript* m_pInstance;
|
||||
|
|
|
|||
|
|
@ -391,7 +391,8 @@ public:
|
|||
switch (action)
|
||||
{
|
||||
case ACTION_START_ESCORT_EVENT:
|
||||
Start(false, true, ObjectGuid::Empty, 0, true, false);
|
||||
me->SetWalk(false);
|
||||
Start(false, ObjectGuid::Empty, 0, true, false);
|
||||
Talk(SAY_BRANN_ESCORT_START);
|
||||
me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
|
|
@ -456,7 +457,8 @@ public:
|
|||
door->SetGoState(GO_STATE_READY);
|
||||
break;
|
||||
case ACTION_OPEN_DOOR:
|
||||
Start(false, true, ObjectGuid::Empty, 0, true, false);
|
||||
me->SetWalk(false);
|
||||
Start(false, ObjectGuid::Empty, 0, true, false);
|
||||
SetNextWaypoint(34, false);
|
||||
SetEscortPaused(false);
|
||||
me->RemoveAura(58506);
|
||||
|
|
@ -571,7 +573,7 @@ public:
|
|||
if (speed < tooFarAwaySpeed)
|
||||
speed = tooFarAwaySpeed;
|
||||
|
||||
darkMatterTarget->MonsterMoveWithSpeed(plr->GetPositionX(), plr->GetPositionY(), plr->GetPositionZ(), speed);
|
||||
darkMatterTarget->GetMotionMaster()->MovePoint(0, plr->GetPositionX(), plr->GetPositionY(), plr->GetPositionZ(), FORCED_MOVEMENT_NONE, speed);
|
||||
|
||||
if (darkMatterTarget->GetDistance(plr) < 15.0f)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -805,7 +805,7 @@ public:
|
|||
case EVENT_LIGHTNING_LAND:
|
||||
{
|
||||
float speed = me->GetDistance(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()) / (1000.0f * 0.001f);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), speed);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), FORCED_MOVEMENT_NONE, speed);
|
||||
events.ScheduleEvent(EVENT_LAND_LAND, 1s);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -381,8 +381,7 @@ public:
|
|||
{
|
||||
me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE);
|
||||
TurnGates(true, false);
|
||||
me->MonsterMoveWithSpeed(homePos.GetPositionX(), homePos.GetPositionY(), homePos.GetPositionZ(), 100.0f);
|
||||
me->UpdatePosition(homePos);
|
||||
me->GetMotionMaster()->MovePoint(0, homePos.GetPositionX(), homePos.GetPositionY(), homePos.GetPositionZ(), FORCED_MOVEMENT_NONE, 100.0f);
|
||||
_speakTimer = 60000;
|
||||
}
|
||||
else if (_speakTimer > 63500)
|
||||
|
|
@ -1090,7 +1089,7 @@ public:
|
|||
{
|
||||
summons.DespawnAll();
|
||||
_spellTimer = 0;
|
||||
Start(false, false, ObjectGuid::Empty, nullptr, false, true);
|
||||
Start(false, ObjectGuid::Empty, nullptr, false, true);
|
||||
if (Aura* aur = me->AddAura(SPELL_FREYA_DUMMY_YELLOW, me))
|
||||
{
|
||||
aur->SetMaxDuration(-1);
|
||||
|
|
|
|||
|
|
@ -601,7 +601,7 @@ public:
|
|||
{
|
||||
me->EnterVehicle(VX001, 4);
|
||||
float speed = ACU->GetDistance(2737.75f, 2574.22f, 381.34f) / 2.0f;
|
||||
ACU->MonsterMoveWithSpeed(2737.75f, 2574.22f, 381.34f, speed);
|
||||
ACU->GetMotionMaster()->MovePoint(0, 2737.75f, 2574.22f, 381.34f, FORCED_MOVEMENT_NONE, speed);
|
||||
ACU->SetPosition(2737.75f, 2574.22f, 381.34f, M_PI);
|
||||
events.ScheduleEvent(EVENT_SAY_VX001_DEAD, 2s);
|
||||
break;
|
||||
|
|
@ -1681,8 +1681,7 @@ public:
|
|||
me->InterruptNonMeleeSpells(false);
|
||||
me->RemoveAllAurasExceptType(SPELL_AURA_CONTROL_VEHICLE);
|
||||
|
||||
me->MonsterMoveWithSpeed(2744.65f, 2569.46f, 381.34f, me->GetDistance(2744.65f, 2569.46f, 381.34f));
|
||||
me->UpdatePosition(2744.65f, 2569.46f, 381.34f, M_PI, false);
|
||||
me->GetMotionMaster()->MovePoint(0, 2744.65f, 2569.46f, 381.34f);
|
||||
|
||||
if (Creature* c = GetMimiron())
|
||||
c->AI()->SetData(0, 3);
|
||||
|
|
@ -1740,8 +1739,7 @@ public:
|
|||
}
|
||||
|
||||
float speed = me->GetExactDist(x, y, 381.34f);
|
||||
me->MonsterMoveWithSpeed(x, y, 381.34f, speed);
|
||||
me->UpdatePosition(x, y, 381.34f, me->GetAngle(victim), false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, 381.34f, FORCED_MOVEMENT_NONE, speed);
|
||||
if (mc)
|
||||
{
|
||||
mc->AI()->SetData(0, 0);
|
||||
|
|
@ -1793,14 +1791,12 @@ public:
|
|||
case EVENT_MAGNETIC_CORE_PULL_DOWN:
|
||||
me->CastSpell(me, SPELL_MAGNETIC_CORE, true);
|
||||
me->CastSpell(me, SPELL_SPINNING, true);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), 365.34f, me->GetExactDist(me->GetPositionX(), me->GetPositionY(), 365.34f));
|
||||
me->UpdatePosition(me->GetPositionX(), me->GetPositionY(), 365.34f, me->GetOrientation(), false);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), 365.34f, FORCED_MOVEMENT_NONE, me->GetExactDist(me->GetPositionX(), me->GetPositionY(), 365.34f));
|
||||
events.ScheduleEvent(EVENT_MAGNETIC_CORE_FREE, 20s);
|
||||
break;
|
||||
case EVENT_MAGNETIC_CORE_FREE:
|
||||
me->RemoveAura(SPELL_SPINNING);
|
||||
me->MonsterMoveWithSpeed(me->GetPositionX(), me->GetPositionY(), 381.34f, me->GetDistance(me->GetPositionX(), me->GetPositionY(), 381.34f));
|
||||
me->UpdatePosition(me->GetPositionX(), me->GetPositionY(), 381.34f, me->GetOrientation(), false);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), 381.34f, FORCED_MOVEMENT_NONE, me->GetDistance(me->GetPositionX(), me->GetPositionY(), 381.34f));
|
||||
events.ScheduleEvent(EVENT_MAGNETIC_CORE_REMOVE_IMMOBILIZE, 1s);
|
||||
break;
|
||||
case EVENT_MAGNETIC_CORE_REMOVE_IMMOBILIZE:
|
||||
|
|
@ -1960,7 +1956,7 @@ public:
|
|||
|
||||
void SetData(uint32 /*id*/, uint32 /*value*/) override
|
||||
{
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 100.0f, false, true);
|
||||
me->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 100.0f, FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 /*diff*/) override
|
||||
|
|
|
|||
|
|
@ -683,7 +683,7 @@ public:
|
|||
{
|
||||
razorscale->AI()->AttackStart(player);
|
||||
razorscale->GetMotionMaster()->MoveIdle();
|
||||
razorscale->GetMotionMaster()->MovePoint(POINT_RAZORSCALE_INIT, 588.0f, -178.0f, 490.0f, false, false);
|
||||
razorscale->GetMotionMaster()->MovePoint(POINT_RAZORSCALE_INIT, 588.0f, -178.0f, 490.0f, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -934,7 +934,8 @@ public:
|
|||
{
|
||||
InitWaypoint();
|
||||
Reset();
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
}
|
||||
|
||||
uint32 Timer;
|
||||
|
|
@ -1020,7 +1021,8 @@ public:
|
|||
{
|
||||
InitWaypoint();
|
||||
Reset();
|
||||
Start(false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false);
|
||||
SetDespawnAtEnd(false);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -937,7 +937,8 @@ public:
|
|||
{
|
||||
InitWaypoint();
|
||||
Reset();
|
||||
Start(false, true, ObjectGuid::Empty, nullptr, false, true);
|
||||
me->SetWalk(false);
|
||||
Start(false, ObjectGuid::Empty, nullptr, false, true);
|
||||
}
|
||||
|
||||
uint32 _checkTimer;
|
||||
|
|
|
|||
|
|
@ -372,7 +372,8 @@ struct violet_hold_trashAI : public npc_escortAI
|
|||
break;
|
||||
}
|
||||
SetDespawnAtEnd(false);
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
}
|
||||
|
||||
npc_escortAI::UpdateAI(diff);
|
||||
|
|
@ -1111,7 +1112,8 @@ public:
|
|||
break;
|
||||
}
|
||||
SetDespawnAtEnd(false);
|
||||
Start(true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true);
|
||||
}
|
||||
|
||||
if (bOpening)
|
||||
|
|
|
|||
|
|
@ -464,7 +464,7 @@ public:
|
|||
go->UseDoorOrButton();
|
||||
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_lurgglbr::npc_lurgglbrAI, creature->AI()))
|
||||
pEscortAI->Start(true, false, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
|
||||
creature->SetFaction(player->GetTeamId() == TEAM_ALLIANCE ? FACTION_ESCORTEE_A_PASSIVE : FACTION_ESCORTEE_H_PASSIVE);
|
||||
return true;
|
||||
|
|
@ -914,7 +914,7 @@ public:
|
|||
creature->SetFaction(player->GetTeamId() == TEAM_ALLIANCE ? FACTION_ESCORTEE_A_PASSIVE : FACTION_ESCORTEE_H_PASSIVE);
|
||||
creature->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
creature->AI()->Talk(SAY_1, player);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, false, player->GetGUID());
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -995,7 +995,8 @@ public:
|
|||
{
|
||||
creature->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
creature->AI()->Talk(SAY_BONKER_2, player);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, true, player->GetGUID());
|
||||
creature->SetWalk(false);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -1884,7 +1885,7 @@ public:
|
|||
if (Creature* leryssa = ObjectAccessor::GetCreature(*me, _leryssaGUID))
|
||||
{
|
||||
leryssa->SetWalk(false);
|
||||
leryssa->MonsterMoveWithSpeed(3726.751f, 3568.1633f, 477.44086f, leryssa->GetSpeed(MOVE_RUN));
|
||||
leryssa->GetMotionMaster()->MovePoint(0, 3726.751f, 3568.1633f, 477.44086f, FORCED_MOVEMENT_RUN);
|
||||
}
|
||||
_events.ScheduleEvent(EVENT_THASSARIAN_SCRIPT_23, 2s);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ struct npc_preparations_for_war_vehicle : public NullCreatureAI
|
|||
}
|
||||
}
|
||||
else
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, false, false);
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z, FORCED_MOVEMENT_NONE, 0.f, 0.f, false, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -592,7 +592,7 @@ struct npc_minigob_manabonk : public ScriptedAI
|
|||
case EVENT_MOVE:
|
||||
{
|
||||
Position pos = me->GetRandomNearPosition((urand(15, 40)));
|
||||
me->GetMotionMaster()->MovePoint(0, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), true);
|
||||
me->GetMotionMaster()->MovePoint(0, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ());
|
||||
}
|
||||
events.ScheduleEvent(EVENT_DESPAWN_VISUAL, 3s);
|
||||
events.ScheduleEvent(EVENT_DESPAWN, 4s);
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ public:
|
|||
Mrfloppy->GetMotionMaster()->MoveFollow(creature, PET_FOLLOW_DIST, PET_FOLLOW_ANGLE);
|
||||
|
||||
if (npc_escortAI* pEscortAI = CAST_AI(npc_emily::npc_emilyAI, (creature->AI())))
|
||||
pEscortAI->Start(true, false, player->GetGUID());
|
||||
pEscortAI->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -191,7 +191,7 @@ public:
|
|||
if (quest->GetQuestId() == QUEST_TRAIL_OF_FIRE)
|
||||
{
|
||||
creature->SetFaction(player->GetTeamId() == TEAM_ALLIANCE ? FACTION_ESCORTEE_A_PASSIVE : FACTION_ESCORTEE_H_PASSIVE);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, false, player->GetGUID());
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -309,7 +309,7 @@ public:
|
|||
return;
|
||||
|
||||
me->SetWalk(true);
|
||||
Start(false, false, summonerGUID);
|
||||
Start(false, summonerGUID);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 waypointId) override
|
||||
|
|
|
|||
|
|
@ -523,11 +523,8 @@ public:
|
|||
{
|
||||
soul->SetCanFly(true);
|
||||
soul->SetVisible(true);
|
||||
Movement::MoveSplineInit init(soul);
|
||||
init.MoveTo(soul->GetPositionX(), soul->GetPositionY(), soul->GetPositionZ() + 5.0f);
|
||||
init.SetVelocity(1.0f);
|
||||
init.Launch();
|
||||
soul->CastSpell(soul, 64462, true); // Drown
|
||||
soul->GetMotionMaster()->MovePoint(0, soul->GetPositionX(), soul->GetPositionY(), soul->GetPositionZ() + 5.0f, FORCED_MOVEMENT_NONE, 1.f);
|
||||
}
|
||||
events.ScheduleEvent(EVENT_SCENE_1, 6s);
|
||||
break;
|
||||
|
|
@ -718,7 +715,7 @@ public:
|
|||
Talk(0);
|
||||
events.Reset();
|
||||
summons.DespawnAll();
|
||||
Start(false, false);
|
||||
Start(false);
|
||||
|
||||
int8 i = -1;
|
||||
std::list<Creature*> cList;
|
||||
|
|
|
|||
|
|
@ -605,7 +605,7 @@ public:
|
|||
creature->GetMotionMaster()->MoveJumpTo(0, 0.4f, 0.4f);
|
||||
creature->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
|
||||
pEscortAI->Start(false, false, player->GetGUID());
|
||||
pEscortAI->Start(false, player->GetGUID());
|
||||
creature->AI()->Talk(SAY_WP_1);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,8 @@ struct npc_frosthound : public npc_escortAI
|
|||
{
|
||||
me->SetFaction(who->GetFaction());
|
||||
me->CastSpell(me, SPELL_SUMMON_PURSUERS_PERIODIC, true);
|
||||
Start(false, true, who->GetGUID());
|
||||
me->SetWalk(false);
|
||||
Start(false, who->GetGUID());
|
||||
Talk(TALK_EMOTE_FROSTHOUND_SNIFF, me);
|
||||
}
|
||||
}
|
||||
|
|
@ -246,7 +247,8 @@ public:
|
|||
void RollPath()
|
||||
{
|
||||
me->SetEntry(NPC_TIME_LOST_PROTO_DRAKE);
|
||||
Start(true, true, ObjectGuid::Empty, 0, false, true, true);
|
||||
me->SetWalk(false);
|
||||
Start(true, ObjectGuid::Empty, 0, false, true, true);
|
||||
SetNextWaypoint(urand(0, 250), true);
|
||||
me->UpdateEntry(roll_chance_i(25) ? NPC_TIME_LOST_PROTO_DRAKE : NPC_VYRAGOSA, 0, false);
|
||||
}
|
||||
|
|
@ -912,7 +914,10 @@ public:
|
|||
if (who->IsPlayer())
|
||||
{
|
||||
if (apply)
|
||||
Start(false, true, who->GetGUID());
|
||||
{
|
||||
me->SetWalk(false);
|
||||
Start(false, who->GetGUID());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -507,7 +507,7 @@ struct boss_illidan_stormrage : public BossAI
|
|||
Talk(SAY_ILLIDAN_EYE_BLAST);
|
||||
me->SummonCreature(NPC_ILLIDAN_DB_TARGET, eyeBeamPos[beamPosId], TEMPSUMMON_TIMED_DESPAWN, 30000);
|
||||
if (Creature* trigger = summons.GetCreatureWithEntry(NPC_ILLIDAN_DB_TARGET))
|
||||
trigger->GetMotionMaster()->MovePoint(0, eyeBeamPos[beamPosId + MAX_EYE_BEAM_POS], false, true);
|
||||
trigger->GetMotionMaster()->MovePoint(0, eyeBeamPos[beamPosId + MAX_EYE_BEAM_POS], FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
|
||||
// Reposition
|
||||
me->m_Events.AddEventAtOffset([&] {
|
||||
|
|
@ -515,7 +515,7 @@ struct boss_illidan_stormrage : public BossAI
|
|||
me->InterruptNonMeleeSpells(false);
|
||||
me->SetControlled(false, UNIT_STATE_ROOT);
|
||||
CycleBeamPos(beamPosId);
|
||||
me->GetMotionMaster()->MovePoint(POINT_ILLIDAN_HOVER, airHoverPos[beamPosId], false, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_ILLIDAN_HOVER, airHoverPos[beamPosId], FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
}, 20s, GROUP_PHASE_FLYING);
|
||||
});
|
||||
// Check for Phase Transition
|
||||
|
|
|
|||
|
|
@ -301,7 +301,7 @@ public:
|
|||
Talk(SUFF_SAY_RECAP);
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->GetMotionMaster()->Clear();
|
||||
me->GetMotionMaster()->MovePoint(POINT_GO_BACK, me->GetHomePosition(), false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_GO_BACK, me->GetHomePosition(), FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
scheduler.CancelAll();
|
||||
}
|
||||
}
|
||||
|
|
@ -408,7 +408,7 @@ public:
|
|||
Talk(DESI_SAY_RECAP);
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->GetMotionMaster()->Clear();
|
||||
me->GetMotionMaster()->MovePoint(POINT_GO_BACK, me->GetHomePosition(), false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_GO_BACK, me->GetHomePosition(), FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
scheduler.CancelAll();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ struct boss_fathomlord_karathress : public BossAI
|
|||
if (Creature* olum = instance->GetCreature(DATA_SEER_OLUM))
|
||||
{
|
||||
olum->SetWalk(true);
|
||||
olum->GetMotionMaster()->MovePoint(0, olumWalk, false);
|
||||
olum->GetMotionMaster()->MovePoint(0, olumWalk, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
olum->SetNpcFlag(UNIT_NPC_FLAG_GOSSIP);
|
||||
olum->SetNpcFlag(UNIT_NPC_FLAG_QUESTGIVER);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ struct boss_lady_vashj : public BossAI
|
|||
scheduler.CancelAll();
|
||||
me->CastStop();
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->GetMotionMaster()->MovePoint(POINT_HOME, me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY(), me->GetHomePosition().GetPositionZ(), true, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_HOME, me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY(), me->GetHomePosition().GetPositionZ(), FORCED_MOVEMENT_NONE, 0.f, true, true);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -102,7 +102,7 @@ struct boss_vazruden_the_herald : public BossAI
|
|||
if (summon->GetEntry() == NPC_HELLFIRE_SENTRY && summons.size() == 0)
|
||||
{
|
||||
Talk(SAY_INTRO);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, -1406.5f, 1746.5f, 85.0f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, -1406.5f, 1746.5f, 85.0f, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
_JustEngagedWith();
|
||||
}
|
||||
else if (summons.size() == 0)
|
||||
|
|
@ -163,7 +163,7 @@ struct boss_nazan : public ScriptedAI
|
|||
_scheduler.CancelAll();
|
||||
_scheduler.Schedule(5ms, GROUP_PHASE_1, [this](TaskContext context)
|
||||
{
|
||||
me->GetMotionMaster()->MovePoint(POINT_FLIGHT, NazanPos[urand(0, 2)], false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_FLIGHT, NazanPos[urand(0, 2)], FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
_scheduler.DelayAll(7s);
|
||||
context.Repeat(30s);
|
||||
}).Schedule(5s, GROUP_PHASE_1, [this](TaskContext context)
|
||||
|
|
@ -193,7 +193,7 @@ struct boss_nazan : public ScriptedAI
|
|||
Talk(EMOTE_NAZAN);
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->InterruptNonMeleeSpells(true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, -1406.5f, 1746.5f, 81.2f, false);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, -1406.5f, 1746.5f, 81.2f, FORCED_MOVEMENT_NONE, 0.f, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@ struct boss_alar : public BossAI
|
|||
_noQuillTimes = 0;
|
||||
_platformRoll = RAND(0, 1);
|
||||
_platform = _platformRoll ? 0 : 3;
|
||||
me->GetMotionMaster()->MovePoint(POINT_QUILL, alarPoints[POINT_QUILL], false, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_QUILL, alarPoints[POINT_QUILL], FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
_platformMoveRepeatTimer = 16s;
|
||||
}
|
||||
else
|
||||
|
|
@ -150,7 +150,7 @@ struct boss_alar : public BossAI
|
|||
me->SetOrientation(alarPoints[_platform].GetOrientation());
|
||||
SpawnPhoenixes(1, me);
|
||||
}
|
||||
me->GetMotionMaster()->MovePoint(POINT_PLATFORM, alarPoints[_platform], false, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_PLATFORM, alarPoints[_platform], FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
_platform = (_platform+1)%4;
|
||||
_platformMoveRepeatTimer = 30s;
|
||||
}
|
||||
|
|
@ -258,7 +258,7 @@ struct boss_alar : public BossAI
|
|||
}, 30s);
|
||||
ScheduleTimedEvent(34s, [&]
|
||||
{
|
||||
me->GetMotionMaster()->MovePoint(POINT_DIVE, alarPoints[POINT_DIVE], false, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_DIVE, alarPoints[POINT_DIVE], FORCED_MOVEMENT_NONE, 0.f, false, true);
|
||||
scheduler.DelayAll(15s);
|
||||
}, 57s);
|
||||
|
||||
|
|
|
|||
|
|
@ -655,7 +655,7 @@ struct boss_kaelthas : public BossAI
|
|||
me->AttackStop();
|
||||
me->CastStop();
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, me->GetHomePosition(), true, true);
|
||||
me->GetMotionMaster()->MovePoint(POINT_MIDDLE, me->GetHomePosition(), FORCED_MOVEMENT_NONE, 0.f, true, true);
|
||||
}
|
||||
});
|
||||
ScheduleTimedEvent(1s, [&]
|
||||
|
|
|
|||
|
|
@ -171,7 +171,7 @@ public:
|
|||
npc_ancestral_wolfAI(Creature* creature) : npc_escortAI(creature)
|
||||
{
|
||||
if (creature->GetOwner() && creature->GetOwner()->IsPlayer())
|
||||
Start(false, false, creature->GetOwner()->GetGUID());
|
||||
Start(false, creature->GetOwner()->GetGUID());
|
||||
creature->SetSpeed(MOVE_WALK, 1.5f);
|
||||
DoCast(SPELL_GUIDED_BY_THE_SPIRITS);
|
||||
Reset();
|
||||
|
|
@ -209,7 +209,7 @@ public:
|
|||
{
|
||||
ryga->SetWalk(true);
|
||||
ryga->SetSpeed(MOVE_WALK, 1.0f);
|
||||
ryga->GetMotionMaster()->MovePoint(0, 515.877991f, 3885.67627f, 190.470535f, true);
|
||||
ryga->GetMotionMaster()->MovePoint(0, 515.877991f, 3885.67627f, 190.470535f, FORCED_MOVEMENT_NONE, 0.f, true);
|
||||
Reset();
|
||||
}
|
||||
}
|
||||
|
|
@ -234,7 +234,7 @@ public:
|
|||
ryga->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
ryga->SetWalk(true);
|
||||
ryga->SetSpeed(MOVE_WALK, 1.0f);
|
||||
ryga->GetMotionMaster()->MovePoint(0, 504.59201f, 3882.12988f, 192.156006f, true);
|
||||
ryga->GetMotionMaster()->MovePoint(0, 504.59201f, 3882.12988f, 192.156006f, FORCED_MOVEMENT_NONE, 0.f, true);
|
||||
Reset();
|
||||
}
|
||||
}
|
||||
|
|
@ -312,7 +312,7 @@ public:
|
|||
{
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
me->SetFaction(FACTION_ESCORTEE_H_PASSIVE);
|
||||
npc_escortAI::Start(true, false, player->GetGUID());
|
||||
npc_escortAI::Start(true, player->GetGUID());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ public:
|
|||
{
|
||||
creature->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
creature->SetFaction(FACTION_ESCORTEE_H_NEUTRAL_ACTIVE);
|
||||
EscortAI->Start(true, false, player->GetGUID(), quest);
|
||||
EscortAI->Start(true, player->GetGUID(), quest);
|
||||
creature->AI()->Talk(SAY_MAG_START);
|
||||
|
||||
creature->SummonCreature(NPC_MURK_RAIDER, m_afAmbushA[0] + 2.5f, m_afAmbushA[1] - 2.5f, m_afAmbushA[2], 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
|
|
@ -133,7 +133,7 @@ public:
|
|||
if (Player* player = GetPlayerForEscort())
|
||||
player->GroupEventHappens(QUEST_TOTEM_KARDASH_H, me);
|
||||
|
||||
SetRun();
|
||||
SetRun(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -306,7 +306,7 @@ public:
|
|||
void SetGUID(ObjectGuid const& guid, int32 /*questId*/) override
|
||||
{
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
Start(true, false, guid);
|
||||
Start(true, guid);
|
||||
Talk(SAY_KUR_START);
|
||||
|
||||
me->SummonCreature(NPC_KUR_MURK_RAIDER, kurenaiAmbushA[0] + 2.5f, kurenaiAmbushA[1] - 2.5f, kurenaiAmbushA[2], 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 50000);
|
||||
|
|
@ -361,7 +361,7 @@ public:
|
|||
if (Player* player = GetPlayerForEscort())
|
||||
player->GroupEventHappens(QUEST_TOTEM_KARDASH_A, me);
|
||||
|
||||
SetRun();
|
||||
SetRun(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -103,7 +103,8 @@ public:
|
|||
{
|
||||
if (type == DATA_START_ENCOUNTER)
|
||||
{
|
||||
Start(true, true, playerGUID);
|
||||
me->SetWalk(false);
|
||||
Start(true, playerGUID);
|
||||
SetEscortPaused(true);
|
||||
started = true;
|
||||
|
||||
|
|
@ -605,7 +606,7 @@ public:
|
|||
creature->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
creature->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE);
|
||||
creature->AI()->Talk(SAY_BESSY_0);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, false, player->GetGUID());
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, player->GetGUID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -771,7 +772,7 @@ public:
|
|||
if (npc_maxx_a_million_escortAI* pEscortAI = CAST_AI(npc_maxx_a_million_escort::npc_maxx_a_million_escortAI, creature->AI()))
|
||||
{
|
||||
creature->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE);
|
||||
pEscortAI->Start(false, false, player->GetGUID());
|
||||
pEscortAI->Start(false, player->GetGUID());
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -617,7 +617,7 @@ public:
|
|||
{
|
||||
case EVENT_WALK_TO_MUTTON:
|
||||
me->SetWalk(true);
|
||||
me->GetMotionMaster()->MovePoint(1, x, y, z, true);
|
||||
me->GetMotionMaster()->MovePoint(1, x, y, z);
|
||||
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_NONE);
|
||||
me->HandleEmoteCommand(EMOTE_ONESHOT_CHEER);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -246,7 +246,7 @@ public:
|
|||
|
||||
Player* player = summoner->ToPlayer();
|
||||
if (player && player->GetQuestStatus(10211) == QUEST_STATUS_INCOMPLETE)
|
||||
Start(false, false, summoner->GetGUID());
|
||||
Start(false, summoner->GetGUID());
|
||||
}
|
||||
|
||||
void Reset() override { }
|
||||
|
|
|
|||
|
|
@ -473,7 +473,7 @@ public:
|
|||
{
|
||||
if (quest->GetQuestId() == QUEST_EFTW_H || quest->GetQuestId() == QUEST_EFTW_A)
|
||||
{
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, false, player->GetGUID());
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, player->GetGUID());
|
||||
creature->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_ACTIVE);
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -1421,7 +1421,8 @@ public:
|
|||
break;
|
||||
}
|
||||
|
||||
Start(false, true);
|
||||
me->SetWalk(true);
|
||||
Start(false);
|
||||
}
|
||||
else
|
||||
EnterEvadeMode(); //something went wrong
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue