aboutsummaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
authorh-v-smacker <hans-von-smacker+github@gmail.com>2017-12-14 17:32:17 +0300
committerh-v-smacker <hans-von-smacker+github@gmail.com>2017-12-14 17:32:17 +0300
commit260b71b2eec88435a144078e30d2b91585243040 (patch)
tree95d3635537a5a84ddaa3795dcb21eb125d649fe7 /init.lua
parent7a5b8895d6f938f1c459bbae73d32464aa435b5a (diff)
downloadfreezer-260b71b2eec88435a144078e30d2b91585243040.tar.gz
freezer-260b71b2eec88435a144078e30d2b91585243040.tar.bz2
freezer-260b71b2eec88435a144078e30d2b91585243040.zip
Added Aspic
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua49
1 files changed, 48 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index f657049..b1cce8f 100644
--- a/init.lua
+++ b/init.lua
@@ -201,6 +201,17 @@ local function freezer_node_timer(pos, elapsed)
end
end
+ -- aspic
+ if minetest.get_modpath("mobs") and mobs and mobs.mod == "redo" and minetest.get_modpath("ethereal") then
+ if inv:contains_item("src", "freezer:meat_broth") then
+ if inv:room_for_item("dst", "freezer:aspic 5") then
+ inv:remove_item("src", "freezer:meat_broth")
+ inv:add_item("dst", "freezer:aspic 5")
+ inv:add_item("dst", "bucket:bucket_empty")
+ end
+ end
+ end
+
-- Check if we have cookable content
return
end
@@ -302,7 +313,43 @@ if minetest.get_modpath("mobs") and mobs and mobs.mod == "redo" then
on_use = minetest.item_eat(1, "default:stick"),
})
end
+
+-- aspic
+-- bones + bucket of water + meat = broth -> freezer -> portions of aspic
+
+if minetest.get_modpath("mobs") and mobs and mobs.mod == "redo" and minetest.get_modpath("ethereal") then
+ minetest.register_craftitem("freezer:meat_broth", {
+ description = "Meat broth",
+ inventory_image = "meat_broth.png",
+ wield_image = "meat_broth.png",
+ stack_max = 99,
+ groups = { },
+ on_use = minetest.item_eat(3, "bucket:bucket_empty"),
+ })
+
+ minetest.register_craft({
+ type = "shapeless",
+ output = "freezer:meat_broth",
+ recipe = {"mobs:meat_raw", "ethereal:bone", "bucket:bucket_river_water"},
+ })
+
+ minetest.register_craft({
+ type = "shapeless",
+ output = "freezer:meat_broth",
+ recipe = {"mobs:meat_raw", "ethereal:bone", "bucket:bucket_water"},
+ })
+ minetest.register_craftitem("freezer:aspic", {
+ description = "A portion of aspic",
+ inventory_image = "aspic.png",
+ wield_image = "aspic.png",
+ stack_max = 99,
+ groups = { not_in_creative_inventory = 1 },
+ on_use = minetest.item_eat(6),
+ })
+end
+
+-- pelmeni (dumplings with meat filling)
if minetest.get_modpath("mobs") and mobs and mobs.mod == "redo" and minetest.get_modpath("farming") then
-- both the dough and the frozen pelmeni are nigh inedible
@@ -313,7 +360,7 @@ if minetest.get_modpath("mobs") and mobs and mobs.mod == "redo" and minetest.get
inventory_image = "pelmeni_raw.png",
wield_image = "pelmeni_raw.png",
stack_max = 99,
- groups = { not_in_creative_inventory = 1 },
+ groups = { },
on_use = minetest.item_eat(1),
})