minetest-mods/farming/crops/ryeoatrice.lua

163 lines
3.5 KiB
Lua
Raw Normal View History

2019-12-14 17:47:31 +01:00
local S = farming.intllib
--= A nice addition from Ademant's grain mod :)
-- Rye
farming.register_plant("farming:rye", {
2021-05-16 18:01:50 +02:00
description = S("Rye seed"),
2019-12-14 17:47:31 +01:00
paramtype2 = "meshoptions",
inventory_image = "farming_rye_seed.png",
steps = 8,
2021-05-16 18:01:50 +02:00
place_param2 = 3
2019-12-14 17:47:31 +01:00
})
minetest.override_item("farming:rye", {
2021-05-16 18:01:50 +02:00
description = S("Rye"),
2019-12-14 17:47:31 +01:00
groups = {food_rye = 1, flammable = 4}
})
minetest.register_craft({
output = "farming:flour",
recipe = {
2021-05-16 18:01:50 +02:00
{"farming:rye", "farming:rye", "farming:rye"},
{"farming:rye", "farming:mortar_pestle", ""}
2019-12-14 17:47:31 +01:00
},
2021-05-16 18:01:50 +02:00
replacements = {{"group:food_mortar_pestle", "farming:mortar_pestle"}}
2019-12-14 17:47:31 +01:00
})
-- Oats
farming.register_plant("farming:oat", {
2021-05-16 18:01:50 +02:00
description = S("Oat seed"),
2019-12-14 17:47:31 +01:00
paramtype2 = "meshoptions",
inventory_image = "farming_oat_seed.png",
steps = 8,
2021-05-16 18:01:50 +02:00
place_param2 = 3
2019-12-14 17:47:31 +01:00
})
minetest.override_item("farming:oat", {
2021-05-16 18:01:50 +02:00
description = S("Oats"),
2019-12-14 17:47:31 +01:00
groups = {food_oats = 1, flammable = 4}
})
minetest.register_craft({
output = "farming:flour",
recipe = {
2021-05-16 18:01:50 +02:00
{"farming:oat", "farming:oat", "farming:oat"},
{"farming:oat", "farming:mortar_pestle", ""}
2019-12-14 17:47:31 +01:00
},
2021-05-16 18:01:50 +02:00
replacements = {{"group:food_mortar_pestle", "farming:mortar_pestle"}}
2019-12-14 17:47:31 +01:00
})
-- Rice
farming.register_plant("farming:rice", {
2021-05-16 18:01:50 +02:00
description = S("Rice grains"),
2019-12-14 17:47:31 +01:00
paramtype2 = "meshoptions",
inventory_image = "farming_rice_seed.png",
steps = 8,
2021-05-16 18:01:50 +02:00
place_param2 = 3
2019-12-14 17:47:31 +01:00
})
minetest.override_item("farming:rice", {
2021-05-16 18:01:50 +02:00
description = S("Rice"),
2019-12-14 17:47:31 +01:00
groups = {food_rice = 1, flammable = 4}
})
minetest.register_craftitem("farming:rice_bread", {
2021-05-16 18:01:50 +02:00
description = S("Rice Bread"),
2019-12-14 17:47:31 +01:00
inventory_image = "farming_rice_bread.png",
on_use = minetest.item_eat(5),
2021-05-16 18:01:50 +02:00
groups = {food_rice_bread = 1, flammable = 2}
2019-12-14 17:47:31 +01:00
})
minetest.register_craftitem("farming:rice_flour", {
2021-05-16 18:01:50 +02:00
description = S("Rice Flour"),
2019-12-14 17:47:31 +01:00
inventory_image = "farming_rice_flour.png",
2021-05-16 18:01:50 +02:00
groups = {food_rice_flour = 1, flammable = 1}
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
output = "farming:rice_flour",
recipe = {
2021-05-16 18:01:50 +02:00
{"farming:rice", "farming:rice", "farming:rice"},
{"farming:rice", "farming:mortar_pestle", ""}
2019-12-14 17:47:31 +01:00
},
2021-05-16 18:01:50 +02:00
replacements = {{"group:food_mortar_pestle", "farming:mortar_pestle"}}
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "cooking",
cooktime = 15,
output = "farming:rice_bread",
recipe = "farming:rice_flour"
})
-- Multigrain flour
minetest.register_craftitem("farming:flour_multigrain", {
description = S("Multigrain Flour"),
inventory_image = "farming_flour_multigrain.png",
groups = {food_flour = 1, flammable = 1},
})
minetest.register_craft({
type = "shapeless",
output = "farming:flour_multigrain",
recipe = {
"farming:wheat", "farming:barley", "farming:oat",
"farming:rye", "farming:mortar_pestle"
},
2021-05-16 18:01:50 +02:00
replacements = {{"group:food_mortar_pestle", "farming:mortar_pestle"}}
2019-12-14 17:47:31 +01:00
})
-- Multigrain bread
minetest.register_craftitem("farming:bread_multigrain", {
description = S("Multigrain Bread"),
inventory_image = "farming_bread_multigrain.png",
on_use = minetest.item_eat(7),
2021-05-16 18:01:50 +02:00
groups = {food_bread = 1, flammable = 2}
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "cooking",
cooktime = 15,
output = "farming:bread_multigrain",
recipe = "farming:flour_multigrain"
})
-- Fuels
minetest.register_craft({
type = "fuel",
recipe = "farming:rice_bread",
2021-05-16 18:01:50 +02:00
burntime = 1
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "fuel",
recipe = "farming:bread_multigrain",
2021-05-16 18:01:50 +02:00
burntime = 1
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "fuel",
recipe = "farming:rye",
2021-05-16 18:01:50 +02:00
burntime = 1
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "fuel",
recipe = "farming:oat",
2021-05-16 18:01:50 +02:00
burntime = 1
2019-12-14 17:47:31 +01:00
})
minetest.register_craft({
type = "fuel",
recipe = "farming:rice",
2021-05-16 18:01:50 +02:00
burntime = 1
2019-12-14 17:47:31 +01:00
})