1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2024-12-12 10:04:40 +02:00

fixed typo in follow.distance() which caused the function to return incorrect results

This commit is contained in:
Valansch 2017-07-30 18:00:28 +02:00
parent 13cf779921
commit a62674e147

View File

@ -40,7 +40,7 @@ end
local function distance(player_1, player_2)
local d_x = player_1.position.x - player_2.position.x
local d_y = player_1.position.y - player_2.position.y
return math.sqrt(d_x*d_x + d_y + d_y)
return math.sqrt(d_x*d_x + d_y * d_y)
end
function walk_on_tick()
if global.follows.n_entries > 0 then