2018-05-10 21:42:24 +02:00
|
|
|
return function(x, y, world)
|
|
|
|
local distance = math.sqrt(x * x + y * y)
|
|
|
|
if distance > 128 then
|
|
|
|
local angle = 180 + math.deg(math.atan2(x, y))
|
|
|
|
|
|
|
|
local offset = distance
|
|
|
|
local offset2 = distance
|
|
|
|
if angle ~= 0 then
|
|
|
|
offset2 = offset - angle / 3.75
|
|
|
|
offset = offset + angle / 3.75
|
2017-07-14 20:12:28 +02:00
|
|
|
end
|
2018-05-10 21:42:24 +02:00
|
|
|
--if angle ~= 0 then offset = offset + angle /1.33333333 end
|
2017-07-18 21:29:12 +02:00
|
|
|
|
2018-05-10 21:42:24 +02:00
|
|
|
if offset % 96 < 64 then
|
|
|
|
return offset2 % 96 >= 64
|
|
|
|
end
|
|
|
|
end
|
2017-07-18 21:29:12 +02:00
|
|
|
|
2017-07-14 20:12:28 +02:00
|
|
|
return true
|
2017-07-18 21:29:12 +02:00
|
|
|
end
|