Core/Spells: Implemented using db2 PositionFacing for SPELL_EFFECT_LEAP_BACK
Port From (https://github.com/TrinityCore/TrinityCore/commit/7295bfb6a09b25d824889cfb3698a0774fc01b34)
This commit is contained in:
@@ -395,9 +395,8 @@ namespace Game.Entities
|
||||
return true;
|
||||
}
|
||||
|
||||
public void JumpTo(float speedXY, float speedZ, bool forward, Position dest = null)
|
||||
public void JumpTo(float speedXY, float speedZ, float angle, Position dest = null)
|
||||
{
|
||||
float angle = forward ? 0 : MathFunctions.PI;
|
||||
if (dest != null)
|
||||
angle += GetRelativeAngle(dest);
|
||||
|
||||
|
||||
@@ -3869,7 +3869,7 @@ namespace Game.Spells
|
||||
float speedxy = effectInfo.MiscValue / 10.0f;
|
||||
float speedz = damage / 10.0f;
|
||||
// Disengage
|
||||
unitTarget.JumpTo(speedxy, speedz, m_spellInfo.IconFileDataId != 132572);
|
||||
unitTarget.JumpTo(speedxy, speedz, effectInfo.PositionFacing);
|
||||
|
||||
// changes fall time
|
||||
if (m_caster.GetTypeId() == TypeId.Player)
|
||||
@@ -3965,7 +3965,7 @@ namespace Game.Spells
|
||||
return;
|
||||
}
|
||||
|
||||
unitTarget.JumpTo(speedXY, speedZ, true, pos);
|
||||
unitTarget.JumpTo(speedXY, speedZ, 0.0f, pos);
|
||||
}
|
||||
|
||||
[SpellEffectHandler(SpellEffectName.PullTowardsDest)]
|
||||
@@ -4002,7 +4002,7 @@ namespace Game.Spells
|
||||
return;
|
||||
}
|
||||
|
||||
unitTarget.JumpTo(speedXY, speedZ, true, pos);
|
||||
unitTarget.JumpTo(speedXY, speedZ, 0.0f, pos);
|
||||
}
|
||||
|
||||
[SpellEffectHandler(SpellEffectName.ChangeRaidMarker)]
|
||||
|
||||
Reference in New Issue
Block a user