Add NoLerp methods for rotation (#4186)

This commit is contained in:
metalgearsloth
2023-07-18 21:40:09 +10:00
committed by GitHub
parent 21e74c9881
commit ce4016965e
2 changed files with 17 additions and 0 deletions
@@ -418,6 +418,16 @@ public abstract partial class SharedTransformSystem
#region Local Rotation
public void SetLocalRotationNoLerp(EntityUid uid, Angle angle)
{
SetLocalRotationNoLerp(_xformQuery.GetComponent(uid), angle);
}
public virtual void SetLocalRotationNoLerp(TransformComponent xform, Angle angle)
{
xform.LocalRotation = angle;
}
public void SetLocalRotation(EntityUid uid, Angle value, TransformComponent? xform = null)
{
if (!Resolve(uid, ref xform)) return;