bd0f201469
This makes it a little easier to discover recipes, since you now generally don't have to get the exact count right anymore; just make sure you at least have enough.
14 lines
455 B
Lua
14 lines
455 B
Lua
-- LUALOCALS < ---------------------------------------------------------
|
|
local minetest, nodecore
|
|
= minetest, nodecore
|
|
-- LUALOCALS > ---------------------------------------------------------
|
|
|
|
function nodecore.buildable_to(thing)
|
|
if not thing.name then
|
|
thing = nodecore.underride(thing, minetest.get_node(thing))
|
|
end
|
|
if thing.name == "ignore" then return end
|
|
local def = minetest.registered_items[thing.name] or {}
|
|
return def.buildable_to
|
|
end
|