mirror of
https://github.com/minetest-mods/towercrane.git
synced 2024-11-26 01:03:45 +01:00
Add get_node_lvm() improvement
This commit is contained in:
parent
4a1b5b2333
commit
e66f262888
12
init.lua
12
init.lua
@ -67,11 +67,13 @@ local function get_node_lvm(pos)
|
|||||||
local param2_data = vm:get_param2_data()
|
local param2_data = vm:get_param2_data()
|
||||||
local area = VoxelArea:new({MinEdge = MinEdge, MaxEdge = MaxEdge})
|
local area = VoxelArea:new({MinEdge = MinEdge, MaxEdge = MaxEdge})
|
||||||
local idx = area:indexp(pos)
|
local idx = area:indexp(pos)
|
||||||
node = {
|
if data[idx] and param2_data[idx] then
|
||||||
name = minetest.get_name_from_content_id(data[idx]),
|
return {
|
||||||
param2 = param2_data[idx]
|
name = minetest.get_name_from_content_id(data[idx]),
|
||||||
}
|
param2 = param2_data[idx]
|
||||||
return node
|
}
|
||||||
|
end
|
||||||
|
return {name="ignore", param2=0}
|
||||||
end
|
end
|
||||||
|
|
||||||
local function turnright(dir)
|
local function turnright(dir)
|
||||||
|
Loading…
Reference in New Issue
Block a user