summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVanessa Ezekowitz <vanessaezekowitz@gmail.com>2016-07-14 07:45:09 -0400
committerGitHub <noreply@github.com>2016-07-14 07:45:09 -0400
commit1b40a02f1c134e78062bf2139a8d3d1924854ec1 (patch)
treeb3dbc3700223953626ead710881e8b0a55e68f3e
parent1645d17c979b40533c4284c93015f59a21bce9b5 (diff)
parentf23b4aed658b829773832fdfe57db358e4259148 (diff)
Merge pull request #57 from pgimeno/exclude-items-from-recipes
Allow items to exclude their recipes from the recipes list
-rw-r--r--api.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/api.lua b/api.lua
index 59296db..872ce32 100644
--- a/api.lua
+++ b/api.lua
@@ -25,7 +25,8 @@ minetest.after(0.01, function()
for _,chk in pairs(recipe.items) do
local groupchk = string.find(chk, "group:")
if (not groupchk and not minetest.registered_items[chk])
- or (groupchk and not unified_inventory.get_group_item(string.gsub(chk, "group:", "")).item) then
+ or (groupchk and not unified_inventory.get_group_item(string.gsub(chk, "group:", "")).item)
+ or minetest.get_item_group(chk, "exclude_from_craft_guide") ~= 0 then
unknowns = true
end
end