Core/Movement: Use SetWalk(true/false) instead of AddUnit/RemoveUnit.
This commit is contained in:
@@ -156,7 +156,7 @@ class instance_deadmines : public InstanceMapScript
|
||||
|
||||
void MoveCreatureInside(Creature* creature)
|
||||
{
|
||||
creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
creature->SetWalk(false);
|
||||
creature->GetMotionMaster()->MovePoint(0, -102.7f, -655.9f, creature->GetPositionZ());
|
||||
}
|
||||
|
||||
|
||||
@@ -122,7 +122,7 @@ public:
|
||||
|
||||
me->SetSpeed(MOVE_RUN, 2.0f);
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_LEVITATING);
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
me->setActive(true);
|
||||
|
||||
if (instance)
|
||||
|
||||
@@ -171,7 +171,7 @@ public:
|
||||
float x, y, z; // coords that we move to, close to the crystal.
|
||||
CrystalChosen->GetClosePoint(x, y, z, me->GetObjectSize(), CONTACT_DISTANCE);
|
||||
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
me->GetMotionMaster()->MovePoint(1, x, y, z);
|
||||
DrainingCrystal = true;
|
||||
}
|
||||
|
||||
@@ -587,7 +587,7 @@ public:
|
||||
return;
|
||||
|
||||
TargetGUID = who->GetGUID();
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
me->SetSpeed(MOVE_RUN, 0.4f);
|
||||
me->GetMotionMaster()->MoveChase(who);
|
||||
me->SetTarget(TargetGUID);
|
||||
@@ -892,7 +892,7 @@ public:
|
||||
{
|
||||
if (Creature* miner = Unit::GetCreature(*me, minerGUID))
|
||||
{
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
|
||||
//Not 100% correct, but movement is smooth. Sometimes miner walks faster
|
||||
//than normal, this speed is fast enough to keep up at those times.
|
||||
|
||||
@@ -400,7 +400,7 @@ public:
|
||||
switch (uiStage)
|
||||
{
|
||||
case 1:
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
if (GameObject* tree = me->FindNearestGameObject(GO_INCONSPICUOUS_TREE, 40.0f))
|
||||
{
|
||||
DoScriptText(SAY_TREE1, me);
|
||||
|
||||
@@ -502,7 +502,7 @@ public:
|
||||
switch (wpId)
|
||||
{
|
||||
case 0:
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
SetHoldState(true);
|
||||
break;
|
||||
case 1:
|
||||
@@ -537,7 +537,7 @@ public:
|
||||
bIsBattle = true;
|
||||
break;
|
||||
case 2:
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
DoCast(me, SPELL_THE_LIGHT_OF_DAWN);
|
||||
break;
|
||||
case 3:
|
||||
@@ -551,30 +551,30 @@ public:
|
||||
{
|
||||
if (temp->HasAura(SPELL_THE_LIGHT_OF_DAWN, 0))
|
||||
temp->RemoveAurasDueToSpell(SPELL_THE_LIGHT_OF_DAWN);
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[19].x, LightofDawnLoc[19].y, LightofDawnLoc[19].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiThassarianGUID))
|
||||
{
|
||||
if (temp->HasAura(SPELL_THE_LIGHT_OF_DAWN, 0))
|
||||
temp->RemoveAurasDueToSpell(SPELL_THE_LIGHT_OF_DAWN);
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[21].x, LightofDawnLoc[21].y, LightofDawnLoc[21].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiKorfaxGUID))
|
||||
{
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_READY2H);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[10].x, LightofDawnLoc[10].y, LightofDawnLoc[10].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiMaxwellGUID))
|
||||
{
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[13].x, LightofDawnLoc[13].y, LightofDawnLoc[13].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiEligorGUID))
|
||||
{
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[16].x, LightofDawnLoc[16].y, LightofDawnLoc[16].z);
|
||||
}
|
||||
JumpToNextStep(10000);
|
||||
@@ -664,7 +664,7 @@ public:
|
||||
if (uiSummon_counter < ENCOUNTER_GHOUL_NUMBER)
|
||||
{
|
||||
Unit* temp = me->SummonCreature(NPC_ACHERUS_GHOUL, (me->GetPositionX()-20)+rand()%40, (me->GetPositionY()-20)+rand()%40, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 300000);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->setFaction(2084);
|
||||
uiGhoulGUID[uiSummon_counter] = temp->GetGUID();
|
||||
++uiSummon_counter;
|
||||
@@ -682,7 +682,7 @@ public:
|
||||
if (uiSummon_counter < ENCOUNTER_ABOMINATION_NUMBER)
|
||||
{
|
||||
Unit* temp = me->SummonCreature(NPC_RAMPAGING_ABOMINATION, (me->GetPositionX()-20)+rand()%40, (me->GetPositionY()-20)+rand()%40, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 300000);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->setFaction(2084);
|
||||
uiAbominationGUID[uiSummon_counter] = temp->GetGUID();
|
||||
++uiSummon_counter;
|
||||
@@ -700,7 +700,7 @@ public:
|
||||
if (uiSummon_counter < ENCOUNTER_WARRIOR_NUMBER)
|
||||
{
|
||||
Unit* temp = me->SummonCreature(NPC_WARRIOR_OF_THE_FROZEN_WASTES, (me->GetPositionX()-20)+rand()%40, (me->GetPositionY()-20)+rand()%40, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 300000);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->setFaction(2084);
|
||||
uiWarriorGUID[uiSummon_counter] = temp->GetGUID();
|
||||
++uiSummon_counter;
|
||||
@@ -718,7 +718,7 @@ public:
|
||||
if (uiSummon_counter < ENCOUNTER_BEHEMOTH_NUMBER)
|
||||
{
|
||||
Unit* temp = me->SummonCreature(NPC_FLESH_BEHEMOTH, (me->GetPositionX()-20)+rand()%40, (me->GetPositionY()-20)+rand()%40, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 300000);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->setFaction(2084);
|
||||
uiBehemothGUID[uiSummon_counter] = temp->GetGUID();
|
||||
++uiSummon_counter;
|
||||
@@ -739,17 +739,17 @@ public:
|
||||
SetHoldState(false);
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiKoltiraGUID))
|
||||
{
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[0].x+rand()%30, LightofDawnLoc[0].y+rand()%30, LightofDawnLoc[0].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiOrbazGUID))
|
||||
{
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[0].x+rand()%30, LightofDawnLoc[0].y+rand()%30, LightofDawnLoc[0].z);
|
||||
}
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiThassarianGUID))
|
||||
{
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[0].x+rand()%30, LightofDawnLoc[0].y+rand()%30, LightofDawnLoc[0].z);
|
||||
}
|
||||
for (uint8 i = 0; i < ENCOUNTER_ABOMINATION_NUMBER; ++i)
|
||||
@@ -824,7 +824,7 @@ public:
|
||||
if (Unit* temp = me->SummonCreature(NPC_DARION_MOGRAINE, LightofDawnLoc[24].x, LightofDawnLoc[24].y, LightofDawnLoc[24].z, LightofDawnLoc[24].o, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 300000))
|
||||
{
|
||||
DoScriptText(SAY_LIGHT_OF_DAWN35, temp);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
uiDarionGUID = temp->GetGUID();
|
||||
}
|
||||
JumpToNextStep(4000);
|
||||
@@ -940,7 +940,7 @@ public:
|
||||
DoCast(me, SPELL_MOGRAINE_CHARGE); // jumping charge
|
||||
// doesn't make it looks well, so workarounds, Darion charges, looks better
|
||||
me->SetSpeed(MOVE_RUN, 3.0f);
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
SetHoldState(false);
|
||||
JumpToNextStep(0);
|
||||
break;
|
||||
@@ -1013,7 +1013,7 @@ public:
|
||||
Unit* temp;
|
||||
temp = me->SummonCreature(NPC_DEFENDER_OF_THE_LIGHT, LightofDawnLoc[0].x+rand()%10, LightofDawnLoc[0].y+rand()%10, LightofDawnLoc[0].z, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10000);
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->SetSpeed(MOVE_RUN, 2.0f);
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->GetMotionMaster()->MovePoint(0, fLichPositionX, fLichPositionY, fLichPositionZ);
|
||||
@@ -1021,7 +1021,7 @@ public:
|
||||
|
||||
temp = me->SummonCreature(NPC_RIMBLAT_EARTHSHATTER, LightofDawnLoc[0].x+rand()%10, LightofDawnLoc[0].y+rand()%10, LightofDawnLoc[0].z, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10000);
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->SetSpeed(MOVE_RUN, 2.0f);
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->GetMotionMaster()->MovePoint(0, fLichPositionX, fLichPositionY, fLichPositionZ);
|
||||
@@ -1030,7 +1030,7 @@ public:
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiMaxwellGUID))
|
||||
{
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->SetSpeed(MOVE_RUN, 2.0f);
|
||||
temp->GetMotionMaster()->MovePoint(0, fLichPositionX, fLichPositionY, fLichPositionZ);
|
||||
DoScriptText(SAY_LIGHT_OF_DAWN50, temp);
|
||||
@@ -1038,7 +1038,7 @@ public:
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiKorfaxGUID))
|
||||
{
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->SetSpeed(MOVE_RUN, 2.0f);
|
||||
temp->HandleEmoteCommand(EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->GetMotionMaster()->MovePoint(0, fLichPositionX, fLichPositionY, fLichPositionZ);
|
||||
@@ -1046,7 +1046,7 @@ public:
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiEligorGUID))
|
||||
{
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_ATTACK_UNARMED);
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->SetSpeed(MOVE_RUN, 2.0f);
|
||||
temp->GetMotionMaster()->MovePoint(0, fLichPositionX, fLichPositionY, fLichPositionZ);
|
||||
}
|
||||
@@ -1111,7 +1111,7 @@ public:
|
||||
|
||||
case 46: // Darion stand up, "not today"
|
||||
me->SetSpeed(MOVE_RUN, 1.0f);
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
DoScriptText(SAY_LIGHT_OF_DAWN53, me);
|
||||
SetHoldState(false); // Darion throws sword
|
||||
@@ -1171,7 +1171,7 @@ public:
|
||||
temp->CastSpell(temp, SPELL_TIRION_CHARGE, false); // jumping charge
|
||||
temp->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_READY2H);
|
||||
temp->SetSpeed(MOVE_RUN, 3.0f); // workarounds, make Tirion still running
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[2].x, LightofDawnLoc[2].y, LightofDawnLoc[2].z);
|
||||
if (Creature* lktemp = Unit::GetCreature(*me, uiLichKingGUID))
|
||||
lktemp->Relocate(LightofDawnLoc[28].x, LightofDawnLoc[28].y, LightofDawnLoc[28].z); // workarounds, he should kick back by Tirion, but here we relocate him
|
||||
@@ -1189,7 +1189,7 @@ public:
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiLichKingGUID))
|
||||
{
|
||||
temp->SetSpeed(MOVE_RUN, 1.0f);
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[29].x, LightofDawnLoc[29].y, LightofDawnLoc[29].z); // 26
|
||||
}
|
||||
JumpToNextStep(4000);
|
||||
@@ -1249,7 +1249,7 @@ public:
|
||||
case 62:
|
||||
if (Creature* temp = Unit::GetCreature(*me, uiTirionGUID))
|
||||
{
|
||||
temp->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(true);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[7].x, LightofDawnLoc[7].y, LightofDawnLoc[7].z);
|
||||
}
|
||||
JumpToNextStep(5500);
|
||||
@@ -1438,7 +1438,7 @@ public:
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->InterruptNonMeleeSpells(false);
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
|
||||
for (uint8 i = 0; i < ENCOUNTER_DEFENDER_NUMBER; ++i)
|
||||
DespawnNPC(uiDefenderGUID[i]);
|
||||
@@ -1460,7 +1460,7 @@ public:
|
||||
temp->CombatStop(true);
|
||||
temp->AttackStop();
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[9].x, LightofDawnLoc[9].y, LightofDawnLoc[9].z);
|
||||
}
|
||||
|
||||
@@ -1471,7 +1471,7 @@ public:
|
||||
temp->CombatStop(true);
|
||||
temp->AttackStop();
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[12].x, LightofDawnLoc[12].y, LightofDawnLoc[12].z);
|
||||
}
|
||||
|
||||
@@ -1482,7 +1482,7 @@ public:
|
||||
temp->CombatStop(true);
|
||||
temp->AttackStop();
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[15].x, LightofDawnLoc[15].y, LightofDawnLoc[15].z);
|
||||
}
|
||||
DespawnNPC(uiRayneGUID);
|
||||
@@ -1494,7 +1494,7 @@ public:
|
||||
temp->CombatStop(true);
|
||||
temp->AttackStop();
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[18].x, LightofDawnLoc[18].y, LightofDawnLoc[18].z);
|
||||
temp->CastSpell(temp, SPELL_THE_LIGHT_OF_DAWN, false);
|
||||
}
|
||||
@@ -1509,7 +1509,7 @@ public:
|
||||
temp->CombatStop(true);
|
||||
temp->AttackStop();
|
||||
temp->setFaction(me->getFaction());
|
||||
temp->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
temp->SetWalk(false);
|
||||
temp->GetMotionMaster()->MovePoint(0, LightofDawnLoc[20].x, LightofDawnLoc[20].y, LightofDawnLoc[20].z);
|
||||
temp->CastSpell(temp, SPELL_THE_LIGHT_OF_DAWN, false);
|
||||
}
|
||||
|
||||
@@ -74,7 +74,7 @@ public:
|
||||
switch (phase)
|
||||
{
|
||||
case 0:
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
me->HandleEmoteCommand(EMOTE_STATE_FLYGRABCLOSED);
|
||||
FlyBackTimer = 500;
|
||||
break;
|
||||
|
||||
@@ -501,7 +501,7 @@ class mob_janalai_hatcher : public CreatureScript
|
||||
|
||||
void Reset()
|
||||
{
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
side =(me->GetPositionY() < 1150);
|
||||
waypoint = 0;
|
||||
isHatching = false;
|
||||
|
||||
@@ -136,7 +136,7 @@ class boss_nalorakk : public CreatureScript
|
||||
inMove = false;
|
||||
waitTimer = 0;
|
||||
me->SetSpeed(MOVE_RUN, 2);
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
}else
|
||||
{
|
||||
(*me).GetMotionMaster()->MovePoint(0, NalorakkWay[7][0], NalorakkWay[7][1], NalorakkWay[7][2]);
|
||||
|
||||
@@ -168,8 +168,10 @@ public:
|
||||
me->AI()->AttackStart(Summ1);
|
||||
break;
|
||||
}
|
||||
case 19: me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING); break;
|
||||
case 25: me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING); break;
|
||||
case 19: me->SetWalk(false);
|
||||
break;
|
||||
case 25: me->SetWalk(true);
|
||||
break;
|
||||
case 30:
|
||||
if (player && player->GetTypeId() == TYPEID_PLAYER)
|
||||
CAST_PLR(player)->GroupEventHappens(QUEST_ESCAPE_FROM_THE_CATACOMBS, me);
|
||||
|
||||
@@ -273,7 +273,7 @@ public:
|
||||
|
||||
void JustSummoned(Creature* summoned)
|
||||
{
|
||||
summoned->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
summoned->SetWalk(false);
|
||||
summoned->GetMotionMaster()->MovePoint(0, m_afAmbushMoveTo[m_iSpawnId].m_fX, m_afAmbushMoveTo[m_iSpawnId].m_fY, m_afAmbushMoveTo[m_iSpawnId].m_fZ);
|
||||
}
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ public:
|
||||
return;
|
||||
|
||||
if (uiI >= 65 && me->GetUnitMovementFlags() == MOVEMENTFLAG_WALKING)
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
|
||||
switch (uiI)
|
||||
{
|
||||
@@ -94,7 +94,7 @@ public:
|
||||
uiPhase = 1;
|
||||
break;
|
||||
case 65:
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(false);
|
||||
break;
|
||||
case 115:
|
||||
player->AreaExploredOrEventHappens(QUEST_MISSING_IN_ACTION);
|
||||
|
||||
@@ -391,7 +391,7 @@ public:
|
||||
{
|
||||
npc_marzon_silent_bladeAI(Creature* creature) : ScriptedAI(creature)
|
||||
{
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
|
||||
me->SetWalk(true);
|
||||
}
|
||||
|
||||
void Reset()
|
||||
|
||||
Reference in New Issue
Block a user