Add pulling rotating the pulled entity (#2449)

This commit is contained in:
DrSmugleaf
2020-10-30 01:05:28 +01:00
committed by GitHub
parent a2de32d4c4
commit cb0937c8b6

View File

@@ -256,6 +256,12 @@ namespace Content.Shared.Physics.Pull
{ {
MovingTo = null; MovingTo = null;
} }
if (LinearVelocity != Vector2.Zero)
{
var angle = LinearVelocity.ToAngle();
ControlledComponent.Owner.Transform.LocalRotation = angle;
}
} }
} }
} }