Fix half of 45 degree sprite issues

This commit is contained in:
metalgearsloth
2021-10-23 14:43:27 +11:00
parent ce58c6688f
commit 7da89765ac

View File

@@ -87,7 +87,7 @@ namespace Robust.Shared.Maths
var ang = Theta % (2 * Math.PI);
if (ang < 0.0f) // convert -PI > PI to 0 > 2PI
ang += 2 * (float) Math.PI;
ang += 2 * Math.PI;
return (Direction) (Math.Floor((ang + CardinalOffset) / CardinalSegment) * 2 % 8);
}