add vegan leather recipe
This commit is contained in:
parent
0abf6cbb19
commit
7baaea1d05
@ -7,3 +7,5 @@ inventory.
|
||||
The original Bags mod was made by Cornernote and modified to work on sfinv, so
|
||||
this mod will work as a direct replacement for Inventory Plus' bags mod and keep
|
||||
it's existing bag contents.
|
||||
|
||||
Vegan leather can be crafted using mushrooms if no suitable mobs mod is found.
|
||||
|
44
init.lua
44
init.lua
@ -245,6 +245,21 @@ sfinv.register_page("sfinv_bags:bags", {
|
||||
end
|
||||
})
|
||||
|
||||
-- vegan leather
|
||||
minetest.register_craftitem(":bags:leather", {
|
||||
description = S("Vegan Leather"),
|
||||
inventory_image = "bags_leather.png",
|
||||
groups = {leather = 8, flammable = 2},
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "bags:leather",
|
||||
recipe = {
|
||||
{"group:mushroom", "group:mushroom", "group:mushroom"},
|
||||
{"group:mushroom", "group:mushroom", "group:mushroom"},
|
||||
{"group:mushroom", "", "group:mushroom"}
|
||||
}
|
||||
})
|
||||
|
||||
-- register bags items
|
||||
minetest.register_craftitem(":bags:small", {
|
||||
@ -272,36 +287,23 @@ minetest.register_tool(":bags:trolley", {
|
||||
})
|
||||
|
||||
|
||||
-- default craft items
|
||||
local item1 = "group:wood"
|
||||
local item2 = "group:stick"
|
||||
|
||||
-- use leather if a mobs mod is found
|
||||
if minetest.get_modpath("mobs")
|
||||
or minetest.get_modpath("petz")
|
||||
or minetest.get_modpath("mesecraft_mobs") then
|
||||
item1 = "group:leather"
|
||||
end
|
||||
|
||||
-- use string if farming found
|
||||
if minetest.get_modpath("farming") then
|
||||
item2 = "farming:string"
|
||||
end
|
||||
-- default craft recipes
|
||||
local string = minetest.get_modpath("farming") and "farming:string" or "group:stick"
|
||||
|
||||
-- register bag crafts
|
||||
minetest.register_craft({
|
||||
output = "bags:small",
|
||||
recipe = {
|
||||
{"", item2, ""},
|
||||
{item1, item1, item1},
|
||||
{item1, item1, item1}
|
||||
{"", string, ""},
|
||||
{"group:leather", "group:leather", "group:leather"},
|
||||
{"group:leather", "group:leather", "group:leather"}
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "bags:medium",
|
||||
recipe = {
|
||||
{"", item2, ""},
|
||||
{"", string, ""},
|
||||
{"bags:small", "bags:small", "bags:small"}
|
||||
}
|
||||
})
|
||||
@ -309,7 +311,7 @@ minetest.register_craft({
|
||||
minetest.register_craft({
|
||||
output = "bags:large",
|
||||
recipe = {
|
||||
{"", item2, ""},
|
||||
{"", string, ""},
|
||||
{"bags:medium", "bags:medium", "bags:medium"}
|
||||
}
|
||||
})
|
||||
@ -317,7 +319,7 @@ minetest.register_craft({
|
||||
minetest.register_craft({
|
||||
output = "bags:trolley",
|
||||
recipe = {
|
||||
{"", item2, ""},
|
||||
{"", string, ""},
|
||||
{"bags:large", "bags:large", "bags:large"}
|
||||
}
|
||||
})
|
||||
|
BIN
textures/bags_leather.png
Normal file
BIN
textures/bags_leather.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 195 B |
Loading…
x
Reference in New Issue
Block a user