From 5b67f8556f77ee9534df0dbb06136da21c4d9b84 Mon Sep 17 00:00:00 2001 From: jimy-byerley Date: Sun, 25 Mar 2018 20:49:21 +0200 Subject: [PATCH] fixed error in marks detections --- elevator.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/elevator.lua b/elevator.lua index 24ebe94..c7eeadd 100644 --- a/elevator.lua +++ b/elevator.lua @@ -143,8 +143,8 @@ local elevator_mark_height = 1.5 function elevator:regenerate_marks() local y = self.object:getyaw() local p = self.object:getpos() - rail_x = p.x + (elevator_radius+1) * math.cos(y) -- rail on the side - rail_z = p.z + (elevator_radius+1) * math.sin(y) + rail_x = p.x + (elevator_radius+0.5) * math.cos(y) -- rail on the side + rail_z = p.z + (elevator_radius+0.5) * math.sin(y) rail_y = p.y+elevator_mark_height+1 while minetest.get_node({x=rail_x, y=rail_y, z=rail_z}).name == elevator_rail do for i,place in pairs(elevator_marks_slots) do