Fix server crash
parent
0dcee15782
commit
1b62b5f613
|
@ -196,6 +196,7 @@ function minecart.is_owner(player, owner)
|
|||
end
|
||||
|
||||
function minecart.get_buffer_pos(pos, player_name)
|
||||
if pos then
|
||||
local pos1 = minecart.find_node_near_lvm(pos, 1, {"minecart:buffer"})
|
||||
if pos1 then
|
||||
local meta = minetest.get_meta(pos1)
|
||||
|
@ -204,8 +205,10 @@ function minecart.get_buffer_pos(pos, player_name)
|
|||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function minecart.get_buffer_name(pos)
|
||||
if pos then
|
||||
local pos1 = minecart.find_node_near_lvm(pos, 1, {"minecart:buffer"})
|
||||
if pos1 then
|
||||
local name = M(pos1):get_string("name")
|
||||
|
@ -215,6 +218,7 @@ function minecart.get_buffer_name(pos)
|
|||
return P2S(pos1)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function minecart.manage_attachment(player, entity, get_on)
|
||||
if not player then
|
||||
|
|
Loading…
Reference in New Issue