Update CloseTo to CloseToPercent (#4708)

This commit is contained in:
metalgearsloth
2021-09-29 20:07:01 +10:00
committed by GitHub
parent fe4a415d3b
commit ad783396f8
18 changed files with 31 additions and 31 deletions

View File

@@ -263,7 +263,7 @@ namespace Content.Client.Tabletop
var max = (eyePosition + size / 2) / eyeScale;
// If 90/270 degrees rotated, flip X and Y
if (MathHelper.CloseTo(eyeRotation.Degrees % 180d, 90d) || MathHelper.CloseTo(eyeRotation.Degrees % 180d, -90d))
if (MathHelper.CloseToPercent(eyeRotation.Degrees % 180d, 90d) || MathHelper.CloseToPercent(eyeRotation.Degrees % 180d, -90d))
{
(min.Y, min.X) = (min.X, min.Y);
(max.Y, max.X) = (max.X, max.Y);