Merge remote-tracking branch 'Eliminationzx/FixJumpDestOrientation' into 3.3.5 (PR #16450) with some minor CS adjustments
This commit is contained in:
commit
cfed2d7a3d
14 files changed
+39
-38
No files matched your search
@@ -157,7 +157,7 @@ public:
|
||||
{
|
||||
if (Creature* target = ObjectAccessor::GetCreature(*summoned, targetGUID))
|
||||
{
|
||||
target->GetMotionMaster()->MoveJump(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ() + 15.0f, 0);
|
||||
target->GetMotionMaster()->MoveJump(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ() + 15.0f, me->GetOrientation(), 0);
|
||||
target->SetPosition(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ()+15.0f, 0.0f);
|
||||
summoned->CastSpell(target, SPELL_RIBBON_OF_SOULS, false);
|
||||
}
|
||||
|
||||
+2
-2
@@ -461,13 +461,13 @@ class boss_toc_champion_controller : public CreatureScript
|
||||
if (playerTeam == ALLIANCE)
|
||||
{
|
||||
temp->SetHomePosition(vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 0);
|
||||
temp->GetMotionMaster()->MoveJump(vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 20.0f, 20.0f);
|
||||
temp->GetMotionMaster()->MoveJump(vChampionJumpTarget[pos], 20.0f, 20.0f);
|
||||
temp->SetOrientation(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
temp->SetHomePosition((ToCCommonLoc[1].GetPositionX()*2)-vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 3);
|
||||
temp->GetMotionMaster()->MoveJump((ToCCommonLoc[1].GetPositionX()*2)-vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 20.0f, 20.0f);
|
||||
temp->GetMotionMaster()->MoveJump((ToCCommonLoc[1].GetPositionX() * 2) - vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), vChampionJumpTarget[pos].GetOrientation(), 20.0f, 20.0f);
|
||||
temp->SetOrientation(3);
|
||||
}
|
||||
}
|
||||
|
||||
+3
-3
@@ -390,7 +390,7 @@ class npc_snobold_vassal : public CreatureScript
|
||||
else if (Unit* target2 = SelectTarget(SELECT_TARGET_RANDOM, 0, 0.0f, true))
|
||||
{
|
||||
_targetGUID = target2->GetGUID();
|
||||
me->GetMotionMaster()->MoveJump(target2->GetPositionX(), target2->GetPositionY(), target2->GetPositionZ(), 15.0f, 15.0f);
|
||||
me->GetMotionMaster()->MoveJump(*target2, 15.0f, 15.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -981,7 +981,7 @@ class boss_icehowl : public CreatureScript
|
||||
events.ScheduleEvent(EVENT_WHIRL, urand(15*IN_MILLISECONDS, 30*IN_MILLISECONDS));
|
||||
return;
|
||||
case EVENT_MASSIVE_CRASH:
|
||||
me->GetMotionMaster()->MoveJump(ToCCommonLoc[1].GetPositionX(), ToCCommonLoc[1].GetPositionY(), ToCCommonLoc[1].GetPositionZ(), 20.0f, 20.0f, 0); // 1: Middle of the room
|
||||
me->GetMotionMaster()->MoveJump(ToCCommonLoc[1], 20.0f, 20.0f, 0); // 1: Middle of the room
|
||||
SetCombatMovement(false);
|
||||
me->AttackStop();
|
||||
_stage = 7; //Invalid (Do nothing more than move)
|
||||
@@ -1034,7 +1034,7 @@ class boss_icehowl : public CreatureScript
|
||||
_trampleTargetY = target->GetPositionY();
|
||||
_trampleTargetZ = target->GetPositionZ();
|
||||
// 2: Hop Backwards
|
||||
me->GetMotionMaster()->MoveJump(2*me->GetPositionX() - _trampleTargetX, 2*me->GetPositionY() - _trampleTargetY, me->GetPositionZ(), 30.0f, 20.0f, 0);
|
||||
me->GetMotionMaster()->MoveJump(2*me->GetPositionX() - _trampleTargetX, 2*me->GetPositionY() - _trampleTargetY, me->GetPositionZ(), me->GetOrientation(), 30.0f, 20.0f, 0);
|
||||
_stage = 7; //Invalid (Do nothing more than move)
|
||||
}
|
||||
else
|
||||
|
||||
@@ -1768,9 +1768,7 @@ class spell_vehicle_throw_passenger : public SpellScriptLoader
|
||||
else
|
||||
{
|
||||
passenger->ExitVehicle();
|
||||
float x, y, z;
|
||||
targets.GetDstPos()->GetPosition(x, y, z);
|
||||
passenger->GetMotionMaster()->MoveJump(x, y, z, targets.GetSpeedXY(), targets.GetSpeedZ());
|
||||
passenger->GetMotionMaster()->MoveJump(*targets.GetDstPos(), targets.GetSpeedXY(), targets.GetSpeedZ());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -444,7 +444,7 @@ class boss_mimiron : public CreatureScript
|
||||
DoCastAOE(SPELL_DESPAWN_ASSAULT_BOTS);
|
||||
me->ExitVehicle();
|
||||
// ExitVehicle() offset position is not implemented, so we make up for that with MoveJump()...
|
||||
me->GetMotionMaster()->MoveJump(me->GetPositionX() + (10.f * std::cos(me->GetOrientation())), me->GetPositionY() + (10.f * std::sin(me->GetOrientation())), me->GetPositionZ(), 10.f, 5.f);
|
||||
me->GetMotionMaster()->MoveJump(me->GetPositionX() + (10.f * std::cos(me->GetOrientation())), me->GetPositionY() + (10.f * std::sin(me->GetOrientation())), me->GetPositionZ(), me->GetOrientation(), 10.f, 5.f);
|
||||
events.ScheduleEvent(EVENT_OUTTRO_1, 7000);
|
||||
}
|
||||
|
||||
|
||||
@@ -238,7 +238,7 @@ public:
|
||||
me->SetInCombatWithZone();
|
||||
instance->SetBossState(DATA_SKADI_THE_RUTHLESS, IN_PROGRESS);
|
||||
instance->DoStartTimedAchievement(ACHIEVEMENT_TIMED_TYPE_EVENT, ACHIEV_TIMED_START_EVENT);
|
||||
me->GetMotionMaster()->MoveJump(Location[0].GetPositionX(), Location[0].GetPositionY(), Location[0].GetPositionZ(), 5.0f, 10.0f);
|
||||
me->GetMotionMaster()->MoveJump(Location[0], 5.0f, 10.0f);
|
||||
me->SetWalk(false);
|
||||
m_uiMountTimer = 1000;
|
||||
Summons.DespawnEntry(NPC_GRAUF);
|
||||
@@ -289,7 +289,7 @@ public:
|
||||
pGrauf->GetMotionMaster()->MoveFall();
|
||||
pGrauf->HandleEmoteCommand(EMOTE_ONESHOT_FLYDEATH);
|
||||
}
|
||||
me->GetMotionMaster()->MoveJump(Location[4].GetPositionX(), Location[4].GetPositionY(), Location[4].GetPositionZ(), 5.0f, 10.0f);
|
||||
me->GetMotionMaster()->MoveJump(Location[4], 5.0f, 10.0f);
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE);
|
||||
Talk(SAY_DRAKE_DEATH);
|
||||
m_uiCrushTimer = 8000;
|
||||
|
||||
@@ -206,7 +206,7 @@ class spell_ioc_parachute_ic : public SpellScriptLoader
|
||||
class StartLaunchEvent : public BasicEvent
|
||||
{
|
||||
public:
|
||||
StartLaunchEvent(float x, float y, float z, ObjectGuid::LowType lowGuid) : _x(x), _y(y), _z(z), _lowGuid(lowGuid)
|
||||
StartLaunchEvent(Position const& pos, ObjectGuid::LowType lowGuid) : _pos(pos), _lowGuid(lowGuid)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -218,15 +218,15 @@ class StartLaunchEvent : public BasicEvent
|
||||
|
||||
player->AddAura(SPELL_LAUNCH_NO_FALLING_DAMAGE, player); // prevents falling damage
|
||||
float speedZ = 10.0f;
|
||||
float dist = player->GetExactDist2d(_x, _y);
|
||||
float dist = player->GetExactDist2d(&_pos);
|
||||
|
||||
player->ExitVehicle();
|
||||
player->GetMotionMaster()->MoveJump(_x, _y, _z, dist, speedZ);
|
||||
player->GetMotionMaster()->MoveJump(_pos, dist, speedZ, EVENT_JUMP, true);
|
||||
return true;
|
||||
}
|
||||
|
||||
private:
|
||||
float _x, _y, _z;
|
||||
Position _pos;
|
||||
ObjectGuid::LowType _lowGuid;
|
||||
};
|
||||
|
||||
@@ -244,11 +244,7 @@ class spell_ioc_launch : public SpellScriptLoader
|
||||
if (!GetCaster()->ToCreature() || !GetExplTargetDest())
|
||||
return;
|
||||
|
||||
float x, y, z;
|
||||
x = GetExplTargetDest()->GetPositionX();
|
||||
y = GetExplTargetDest()->GetPositionY();
|
||||
z = GetExplTargetDest()->GetPositionZ();
|
||||
GetCaster()->ToCreature()->m_Events.AddEvent(new StartLaunchEvent(x, y, z, GetHitPlayer()->GetGUID().GetCounter()), GetCaster()->ToCreature()->m_Events.CalculateTime(2500));
|
||||
GetCaster()->ToCreature()->m_Events.AddEvent(new StartLaunchEvent(*GetExplTargetDest(), GetHitPlayer()->GetGUID().GetCounter()), GetCaster()->ToCreature()->m_Events.CalculateTime(2500));
|
||||
}
|
||||
|
||||
void Register() override
|
||||
|
||||
Reference in new issue
Block a user