From fbe43fcb8e87552a79cde89585d62aa05b74803a Mon Sep 17 00:00:00 2001 From: JoseDouglas26 Date: Wed, 12 Jun 2024 09:25:09 -0300 Subject: [PATCH] Food items --- mods/ITEMS/food/natural.lua | 30 +++++++++++++++++++++++++----- 1 file changed, 25 insertions(+), 5 deletions(-) diff --git a/mods/ITEMS/food/natural.lua b/mods/ITEMS/food/natural.lua index 95f7d1a95..d9608bd8d 100644 --- a/mods/ITEMS/food/natural.lua +++ b/mods/ITEMS/food/natural.lua @@ -1,14 +1,34 @@ local items = { - ["apple"] = {}, - ["baked_potato"] = {}, - ["beetroot"] = {}, - ["carrot"] = {}, + ["apple"] = { + groups = {compostability = 65, food_and_drinks = 1, saturation = 24}, + on_place = minetest.item_eat(4), + on_secondary_use = minetest.item_eat(4) + }, + ["baked_potato"] = { + groups = {compostability = 85, food_and_drinks = 1, saturation = 60}, + on_place = minetest.item_eat(5), + on_secondary_use = minetest.item_eat(5) + }, + ["beetroot"] = { + groups = {compostability = 65, food_and_drinks = 1, saturation = 12}, + on_place = minetest.item_eat(1), + on_secondary_use = minetest.item_eat(1) + }, + ["carrot"] = { + groups = {compostability = 65, food_and_drinks = 1, saturation = 36}, + on_place = nil, + on_secondary_use = minetest.item_eat(3) + }, ["chorus_fruit"] = {}, ["glow_berries"] = {}, ["melon_slice"] = {}, ["sweet_berries"] = {}, ["poisonous_potato"] = {}, - ["potato"] = {}, + ["potato"] = { + groups = {compostability = 65, food_and_drinks = 1, saturation = 6, smoker_cookable = 1}, + on_place = nil, + on_secondary_use = minetest.item_eat(1) + }, ["spider_eye"] = {} }