Fixes moving in space.

This commit is contained in:
Vera Aguilera Puerto
2021-12-27 21:10:10 +01:00
parent 10fd374a2a
commit 7a61f784ca
2 changed files with 6 additions and 6 deletions

View File

@@ -85,9 +85,7 @@ namespace Content.Shared.Movement
var worldTotal = _relativeMovement ? parentRotation.RotateVec(total) : total;
if (transform.GridID == GridId.Invalid)
worldTotal = mover.LastGridAngle.RotateVec(worldTotal);
else
if (transform.GridID != GridId.Invalid)
mover.LastGridAngle = parentRotation;
if (worldTotal != Vector2.Zero)
@@ -148,9 +146,7 @@ namespace Content.Shared.Movement
if (weightless)
worldTotal *= mobMover.WeightlessStrength;
if (transform.GridID == GridId.Invalid)
worldTotal = mover.LastGridAngle.RotateVec(worldTotal);
else
if (transform.GridID != GridId.Invalid)
mover.LastGridAngle = parentRotation;
if (worldTotal != Vector2.Zero)