From 32a96c4494779805ef07d10cf6705bfb668816e9 Mon Sep 17 00:00:00 2001 From: IamPyu Date: Thu, 31 Oct 2024 19:18:50 -0600 Subject: [PATCH] Many minor changes, also add pumpkins --- CHANGELOG.md | 1 + mods/ITEMS/pyutest_farming/api.lua | 48 +++++++++++----------- mods/ITEMS/pyutest_farming/init.lua | 22 ++++++++++ mods/ITEMS/pyutest_lootboxes/init.lua | 4 +- mods/WORLD/pyutest_overworld/features.lua | 3 +- textures/pyutest-pumpkin-bottom.png | Bin 0 -> 201 bytes textures/pyutest-pumpkin-sides.png | Bin 0 -> 150 bytes textures/pyutest-pumpkin-top.png | Bin 0 -> 235 bytes 8 files changed, 53 insertions(+), 25 deletions(-) create mode 100644 textures/pyutest-pumpkin-bottom.png create mode 100644 textures/pyutest-pumpkin-sides.png create mode 100644 textures/pyutest-pumpkin-top.png diff --git a/CHANGELOG.md b/CHANGELOG.md index 88a7f88..7899a60 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,6 +26,7 @@ - Remove the Slime and Mushroom world because adding content for all 5 different worlds is gonna be hard. - Water and Lava now have "chemical reactions" - Added Calcite +- Added Pumpkins - A lot of other changes that I forgot to document ## [Oct 19th 2024] Bugfix Update diff --git a/mods/ITEMS/pyutest_farming/api.lua b/mods/ITEMS/pyutest_farming/api.lua index cdce56c..e725102 100644 --- a/mods/ITEMS/pyutest_farming/api.lua +++ b/mods/ITEMS/pyutest_farming/api.lua @@ -24,7 +24,7 @@ PyuTest.make_item("pyutest_farming:hoe", "Hoe", { end }) -PyuTest.make_crop = function (name, desc, output, growtime, water_multiplier, textures) +PyuTest.make_crop = function (name, desc, output, growtime, water_multiplier, textures, grow_into) local t = textures or {} PyuTest.make_node(name.."_crop", desc .. "Crop", { @@ -52,32 +52,34 @@ PyuTest.make_crop = function (name, desc, output, growtime, water_multiplier, te timer:start(time) end, on_timer = function (pos) - minetest.set_node(pos, {name = name.."_grown"}) + minetest.set_node(pos, {name = grow_into or name.."_grown"}) end }) - PyuTest.make_node(name.."_grown", desc .. " Crop", { - flammable = 1, - dig_immediate = 3, - attached_node = 3, - oddly_breakable_by_hand = PyuTest.BLOCK_FAST, - not_in_creative_inventory = 1 - }, {t["grown"] or "pyutest-crop-grown.png"}, { - drawtype = "plantlike", - color = t["grown_color"], - paramtype = "light", - sunlight_propagates = true, - walkable = false, - floodable = true, - drop = { - max_items = 1, - items = { - { - items = {ItemStack(name.."_seeds 3"), ItemStack(output)} + if not grow_into then + PyuTest.make_node(name.."_grown", desc .. " Crop", { + flammable = 1, + dig_immediate = 3, + attached_node = 3, + oddly_breakable_by_hand = PyuTest.BLOCK_FAST, + not_in_creative_inventory = 1 + }, {t["grown"] or "pyutest-crop-grown.png"}, { + drawtype = "plantlike", + color = t["grown_color"], + paramtype = "light", + sunlight_propagates = true, + walkable = false, + floodable = true, + drop = { + max_items = 1, + items = { + { + items = {ItemStack(name.."_seeds 3"), ItemStack(output)} + } } - } - }, - }) + }, + }) + end PyuTest.make_item(name.."_seeds", desc.." Seeds", {seeds = 1}, t["seed"] or "pyutest-seeds.png", { color = t["seed_color"], diff --git a/mods/ITEMS/pyutest_farming/init.lua b/mods/ITEMS/pyutest_farming/init.lua index ed3dc6f..c1588da 100644 --- a/mods/ITEMS/pyutest_farming/init.lua +++ b/mods/ITEMS/pyutest_farming/init.lua @@ -23,3 +23,25 @@ PyuTest.make_crop("pyutest_farming:potato", "Potato", "pyutest_tools:potato 5", grown_color = "#9e7b58", seed_color = "#9e7b58" }) + +PyuTest.make_node("pyutest_farming:pumpkin", "Pumpkin", { + oddly_breakable_by_hand = PyuTest.BLOCK_SLOW, + choppy = PyuTest.BLOCK_FAST +}, { + "pyutest-pumpkin-top.png", + "pyutest-pumpkin-bottom.png", + "pyutest-pumpkin-sides.png" +}, {}) + +PyuTest.make_crop("pyutest_farming:pumpkin", "Pumpkin", "", to_minutes(8), 0.33, { + crop_color = "#ce6b28", + seed_color = "#ce6b28" +}, "pyutest_farming:pumpkin") + +minetest.register_craft({ + output = "pyutest_farming:pumpkin_seeds 4", + recipe = { + "pyutest_farming:pumpkin" + }, + type = "shapeless" +}) diff --git a/mods/ITEMS/pyutest_lootboxes/init.lua b/mods/ITEMS/pyutest_lootboxes/init.lua index ba4750f..49df431 100644 --- a/mods/ITEMS/pyutest_lootboxes/init.lua +++ b/mods/ITEMS/pyutest_lootboxes/init.lua @@ -67,5 +67,7 @@ PyuTest.make_lootbox("pyutest_lootboxes:color", "Color", { PyuTest.make_lootbox("pyutest_lootboxes:farming", "Farmer's", { ItemStack("pyutest_farming:wheat_seeds 5"), - ItemStack("pyutest_farming:carrot_seeds 3") + ItemStack("pyutest_farming:carrot_seeds 3"), + ItemStack("pyutest_farming:potato_seeds 3"), + ItemStack("pyutest_farming:pumpkin_seeds 4"), }, true) diff --git a/mods/WORLD/pyutest_overworld/features.lua b/mods/WORLD/pyutest_overworld/features.lua index 2592464..eb08493 100644 --- a/mods/WORLD/pyutest_overworld/features.lua +++ b/mods/WORLD/pyutest_overworld/features.lua @@ -40,6 +40,7 @@ minetest.register_ore({ y_max = PyuTest.BIOME_TOPS.mountains, y_min = PyuTest.BIOME_TOPS.normal, noise_params = PyuTest.MOUNTAIN_STRIP_NOISE_PARAMS, - column_height_max = 12, + column_height_max = 18, column_height_min = 8, + column_midpoint_factor = 1, }) diff --git a/textures/pyutest-pumpkin-bottom.png b/textures/pyutest-pumpkin-bottom.png new file mode 100644 index 0000000000000000000000000000000000000000..ce3fe75f72dc5d9c9fac2c441ba4b098762c230f GIT binary patch literal 201 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`6FglULo9li1{(@BDDbSd?VB6_ z!~FlN@EejBR>o+qe0t8u%q(+7#hvRvFYv2WYV73SWHv9W<<^Xjj))^p3#2+z8Qyp8 zDVgjvTfw=tRm*N0kjScN|%AjqH-Ye6FZqbi9~r)KR=#5a>1rPgg&ebxsLQ0Qvh+ A0{{R3 literal 0 HcmV?d00001 diff --git a/textures/pyutest-pumpkin-sides.png b/textures/pyutest-pumpkin-sides.png new file mode 100644 index 0000000000000000000000000000000000000000..06d691b77baaa4e409039e53f273810a3874c78e GIT binary patch literal 150 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`v7RoDAr`&KHq+OBoZrZFfF+q@ z)8FRHOE%1u&|vX7vCY`Pz+lgR*Bd@5rdJ9X@A5i)Gx{3i;Pc?2DTDZdG=pmq4t^>j wrHn_}1d0SNHg@RvU(HByG?x{Zp4qR%$B+=Jd9a#yCCEMoPgg&ebxsLQ0E(P3E&u=k literal 0 HcmV?d00001 diff --git a/textures/pyutest-pumpkin-top.png b/textures/pyutest-pumpkin-top.png new file mode 100644 index 0000000000000000000000000000000000000000..a4d91407634d32a02a76d3f9f7a7b402f1f819c8 GIT binary patch literal 235 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`n><|{Lo9li1{v}lGT^aU(=k`R zWYsTow`+ZC{z~yDJYv7Oc$Gm2Uty8o#2qKgYMysbzWmr~???6~w&|azbsKh`luQz0 zXwZn{)=5v1RoFktro1h%%fPX0YXg^;j&%Nc+qh%b1i!}kg>Py<))>Xw@H_kL)=G|! zm(~qj72o6C7&n;Kx;5x#$T8jRJZ5-uU-Pa;!9D8doHU`8P%xy@Ed+JS`4D*E4v!`njxgN@xNAHHll* literal 0 HcmV?d00001