mirror of
https://github.com/Refactorio/RedMew.git
synced 2024-12-14 10:13:13 +02:00
17 lines
363 B
Lua
17 lines
363 B
Lua
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
|
|
if angle ~= 0 then
|
|
offset = offset + angle / 3.75
|
|
end
|
|
--if angle ~= 0 then offset = offset + angle /1.33333333 end
|
|
|
|
return offset % 96 >= 48
|
|
end
|
|
|
|
return true
|
|
end
|