summaryrefslogtreecommitdiff
path: root/cow.lua
diff options
context:
space:
mode:
authorTenPlus1 <kinsellaja@yahoo.com>2018-05-06 15:03:59 +0100
committerTenPlus1 <kinsellaja@yahoo.com>2018-05-06 15:03:59 +0100
commitf42a8ba97e4fa9beef2e46f02ffe9e5af248a195 (patch)
tree2899f078efc20f3eb4ca8c528ec98db970362ac6 /cow.lua
parent8f5dac38dca20da23198606f0895f05c03ff03cf (diff)
added butter
Diffstat (limited to 'cow.lua')
-rw-r--r--cow.lua24
1 files changed, 24 insertions, 0 deletions
diff --git a/cow.lua b/cow.lua
index 8427037..fef0703 100644
--- a/cow.lua
+++ b/cow.lua
@@ -128,6 +128,30 @@ minetest.register_craftitem(":mobs:bucket_milk", {
groups = {food_milk = 1, flammable = 3},
})
+-- butter
+minetest.register_craftitem(":mobs:butter", {
+ description = S("Butter"),
+ inventory_image = "mobs_butter.png",
+ on_use = minetest.item_eat(1),
+ groups = {food_butter = 1, flammable = 2},
+})
+
+if minetest.get_modpath("farming") and farming and farming.mod then
+minetest.register_craft({
+ type = "shapeless",
+ output = "mobs:butter",
+ recipe = {"mobs:bucket_milk", "farming:salt"},
+ replacements = {{ "mobs:bucket_milk", "bucket:bucket_empty"}}
+})
+else -- some saplings are high in sodium so makes a good replacement item
+minetest.register_craft({
+ type = "shapeless",
+ output = "mobs:butter",
+ recipe = {"mobs:bucket_milk", "default:sapling"},
+ replacements = {{ "mobs:bucket_milk", "bucket:bucket_empty"}}
+})
+end
+
-- cheese wedge
minetest.register_craftitem(":mobs:cheese", {
description = S("Cheese"),