Bandaid InRangeUnoccluded length checks (#13568)

This commit is contained in:
metalgearsloth
2023-01-21 01:19:01 +11:00
committed by GitHub
parent 9ab1dad456
commit 112e8e33db

View File

@@ -162,7 +162,8 @@ namespace Content.Shared.Examine
var length = dir.Length;
// If range specified also check it
if (range > 0f && length > range) return false;
// TODO: This rounding check is here because the API is kinda eh
if (range > 0f && length > range + 0.01f) return false;
if (MathHelper.CloseTo(length, 0)) return true;