Add potatoes, french fries and frying pans!

This commit is contained in:
IamPyu
2024-10-17 15:28:36 -06:00
parent b874c556c8
commit 3123cda4d7
13 changed files with 405 additions and 5 deletions

View File

@@ -49,7 +49,7 @@ PyuTest.make_sword = function (nsname, desc, texture, damage, durability, atkspe
})
end
PyuTest.make_food = function (nsname, desc, wield_image, health_fill, extra_code)
PyuTest.make_food = function (nsname, desc, wield_image, health_fill, cook_into, extra_code)
local code = extra_code or function()end
PyuTest.make_item(nsname, desc, {
@@ -60,6 +60,7 @@ PyuTest.make_food = function (nsname, desc, wield_image, health_fill, extra_code
minetest.sound_play({name = "eat", gain = 1}, {pos = user:get_pos(), start_time = 1.2})
minetest.do_item_eat(health_fill, "", itemstack, user, pt)
code()
end
end,
__pyutest_cook_into = cook_into
})
end

View File

@@ -3,3 +3,7 @@ PyuTest.make_food("pyutest_tools:bread", "Bread", "pyutest-bread.png", 4)
PyuTest.make_food("pyutest_tools:carrot", "Carrot", "pyutest-carrot.png", 7)
PyuTest.make_food("pyutest_tools:banana", "Banana", "pyutest-banana.png", 6)
PyuTest.make_food("pyutest_tools:water_bottle", "Water Bottle", "pyutest-water-bottle.png", 0)
PyuTest.make_food("pyutest_tools:potato", "Potato", "pyutest-potato.png", 3, "pyutest_tools:cooked_potato")
PyuTest.make_food("pyutest_tools:cooked_potato", "Cooked Potato", "pyutest-cooked-potato.png", 7)
PyuTest.make_food("pyutest_tools:sliced_potato", "Sliced Potato", "pyutest-sliced-potato.png", 0.5, "pyutest_tools:french_fries")PyuTest.make_food("pyutest_tools:french_fries", "French Fries", "pyutest-french-fries.png", 6.5)