Improve doc/lua_api.txt and add minetest.get_item_group(name, group)
This commit is contained in:
parent
5c484429fe
commit
3a248a56d3
|
@ -55,11 +55,15 @@ function minetest.hash_node_position(pos)
|
||||||
return (pos.z+32768)*65536*65536 + (pos.y+32768)*65536 + pos.x+32768
|
return (pos.z+32768)*65536*65536 + (pos.y+32768)*65536 + pos.x+32768
|
||||||
end
|
end
|
||||||
|
|
||||||
function minetest.get_node_group(name, group)
|
function minetest.get_item_group(name, group)
|
||||||
if not minetest.registered_nodes[name] or not
|
if not minetest.registered_items[name] or not
|
||||||
minetest.registered_nodes[name].groups[group] then
|
minetest.registered_items[name].groups[group] then
|
||||||
return 0
|
return 0
|
||||||
end
|
end
|
||||||
return minetest.registered_nodes[name].groups[group]
|
return minetest.registered_items[name].groups[group]
|
||||||
|
end
|
||||||
|
|
||||||
|
function minetest.get_node_group(name, group)
|
||||||
|
return minetest.get_item_group(name, group)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue