From 18936b10e1fee38e55d22bc135b7c7d55fb16224 Mon Sep 17 00:00:00 2001 From: PHIDIAS Date: Wed, 26 Mar 2025 20:13:16 +0900 Subject: [PATCH] . --- PHI-CL/control.lua | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/PHI-CL/control.lua b/PHI-CL/control.lua index 2a37e77..39929ca 100644 --- a/PHI-CL/control.lua +++ b/PHI-CL/control.lua @@ -67,11 +67,8 @@ if settings.startup['PHI-CT'].value then end) function math2d.position.equal(p1, p2) - -- Add nil check and explicit conversion - p1 = math2d.position.ensure_xy(p1 or {x = 0, y = 0}) - p2 = math2d.position.ensure_xy(p2 or {x = 0, y = 0}) - -- Add floating point tolerance (1e-6) for coordinate comparison - return math.abs(p1.x - p2.x) < 1e-6 and math.abs(p1.y - p2.y) < 1e-6 + p1, p2 = math2d.position.ensure_xy(p1), math2d.position.ensure_xy(p2) + return p1.x == p2.x and p1.y == p2.y end function math2d.position.split(pos)