Core/Movement: move MoveSplineInit

Port From (https://github.com/TrinityCore/TrinityCore/commit/d59a6af9c694713fd868db4bae09df3f8b9e041e)
This commit is contained in:
hondacrx
2021-09-26 13:45:04 -04:00
parent 365da29692
commit 53ad19d2f9
9 changed files with 144 additions and 104 deletions
+2 -2
View File
@@ -205,7 +205,7 @@ namespace Game.Entities
MoveSplineInit init = new(this);
init.MoveTo(GetPositionX(), GetPositionY(), GetPositionZ(), false);
init.SetFacing(ori);
init.Launch();
GetMotionMaster().LaunchMoveSpline(init, EventId.Face, MovementSlot.Controlled);
}
public void SetFacingToObject(WorldObject obj, bool force = true)
@@ -223,7 +223,7 @@ namespace Game.Entities
MoveSplineInit init = new(this);
init.MoveTo(x, y, z, generatePath, forceDestination);
init.SetVelocity(speed);
init.Launch();
GetMotionMaster().LaunchMoveSpline(init, 0, MovementSlot.Active, MovementGeneratorType.Point);
}
public void KnockbackFrom(float x, float y, float speedXY, float speedZ, SpellEffectExtraData spellEffectExtraData = null)