Leveling system

This commit is contained in:
Alexey 2025-06-25 16:51:23 +03:00
commit efe9f386bd
6 changed files with 83 additions and 26 deletions

View file

@ -8,7 +8,6 @@ require 'gridpoint'
---@field points GridPoint[]
---@field color Color
Line = {
startpoint = GridPoint:new( GridPoint:coords() ),
endpoint = GridPoint:new( GridPoint:coords() ),
points = { },
@ -95,3 +94,8 @@ function Line:has( point )
end
)
end
-- Check if line's endpoints are connected
function Line:endpointsConnected()
return self.points[#self.points]:equals( self.endpoint )
end