From 17371ad60b9ed771967e81b747008630a8a23c4e Mon Sep 17 00:00:00 2001 From: PrairieWind Date: Mon, 19 Jun 2023 10:14:30 -0600 Subject: [PATCH] Cherry blossom changes as requested --- mods/ITEMS/mcl_cherry_blossom/crafting.lua | 12 ++++++------ mods/ITEMS/mcl_cherry_blossom/mod.conf | 2 +- mods/ITEMS/mcl_cherry_blossom/nodes.lua | 6 +++--- mods/ITEMS/mcl_dye/init.lua | 6 +++++- 4 files changed, 15 insertions(+), 11 deletions(-) diff --git a/mods/ITEMS/mcl_cherry_blossom/crafting.lua b/mods/ITEMS/mcl_cherry_blossom/crafting.lua index 16f4016b2..397f23eab 100644 --- a/mods/ITEMS/mcl_cherry_blossom/crafting.lua +++ b/mods/ITEMS/mcl_cherry_blossom/crafting.lua @@ -27,7 +27,7 @@ minetest.register_craft({ }) minetest.register_craft({ - output = "mcl_chery_blossom:cherrydoor 3", + output = "mcl_cherry_blossom:cherry_door 3", recipe = { {planks, planks}, {planks, planks}, @@ -36,7 +36,7 @@ minetest.register_craft({ }) minetest.register_craft({ - output = "mcl_cherry_blossom:cherrytrapdoor 2", + output = "mcl_cherry_blossom:cherry_trapdoor 2", recipe = { {planks, planks, planks}, {planks, planks, planks}, @@ -44,14 +44,14 @@ minetest.register_craft({ }) minetest.register_craft({ - output = "mcl_fences:cherry_fence 3", + output = "mcl_cherry_blossom:cherry_fence 3", recipe = { {planks, "mcl_core:stick", planks}, {planks, "mcl_core:stick", planks}, } }) minetest.register_craft({ - output = "mcl_fences:cherry_fence_gate", + output = "mcl_cherry_blossom:cherry_fence_gate", recipe = { {"mcl_core:stick", planks, "mcl_core:stick"}, {"mcl_core:stick", planks, "mcl_core:stick"}, @@ -63,13 +63,13 @@ mcl_signs.register_sign_craft("mcl_cherry_blossom", "mcl_cherry_blossom:cherrywo -- Smelting minetest.register_craft({ type = "fuel", - recipe = "mcl_cherry_blossom:cherrydoor", + recipe = "mcl_cherry_blossom:cherry_door", burntime = 10, }) minetest.register_craft({ type = "fuel", - recipe = "mcl_cherry_blossom:cherrytrapdoor", + recipe = "mcl_cherry_blossom:cherry_trapdoor", burntime = 15, }) diff --git a/mods/ITEMS/mcl_cherry_blossom/mod.conf b/mods/ITEMS/mcl_cherry_blossom/mod.conf index 1b30ed062..8a6975946 100644 --- a/mods/ITEMS/mcl_cherry_blossom/mod.conf +++ b/mods/ITEMS/mcl_cherry_blossom/mod.conf @@ -1,3 +1,3 @@ title = mcl_cherry_blossom -author = PrairieWind +author = PrairieWind, Wbjitscool, SmokeyDope depends = mcl_sounds, mcl_util, mcl_core, mcl_doors, mcl_stairs, mcl_signs, mcl_fences, mesecons_pressureplates, mesecons_button, mcl_boats diff --git a/mods/ITEMS/mcl_cherry_blossom/nodes.lua b/mods/ITEMS/mcl_cherry_blossom/nodes.lua index af274f7b9..a36b47595 100644 --- a/mods/ITEMS/mcl_cherry_blossom/nodes.lua +++ b/mods/ITEMS/mcl_cherry_blossom/nodes.lua @@ -16,7 +16,7 @@ mcl_core.register_wooden_planks("cherrywood", S("Cherry Wood Planks"), {"mcl_che -- Leaves mcl_core.register_leaves("cherryleaves", S("Cherry Leaves"), S("Cherry blossom leaves are grown from cherry blossom trees."), {"mcl_cherry_blossom_leaves.png"}, - nil, "none", nil, "mcl_cherry_blossom:cherrysapling", false, {50, 45, 30, 35, 10}) + nil, "none", nil, "mcl_cherry_blossom:cherrysapling", false, {20, 16, 12, 10}) -- Sapling mcl_core.register_sapling("cherrysapling", S("Cherry Sapling"), @@ -24,7 +24,7 @@ mcl_core.register_sapling("cherrysapling", S("Cherry Sapling"), "mcl_cherry_blossom_sapling.png", {-4/16, -0.5, -4/16, 4/16, 0.25, 4/16}) -- Door and Trapdoor -mcl_doors:register_door("mcl_cherry_blossom:cherrydoor", { +mcl_doors:register_door("mcl_cherry_blossom:cherry_door", { description = S("Cherry Door"), inventory_image = "mcl_cherry_blossom_door_inv.png", groups = {handy=1,axey=1, material_wood=1, flammable=-1}, @@ -35,7 +35,7 @@ mcl_doors:register_door("mcl_cherry_blossom:cherrydoor", { sounds = mcl_sounds.node_sound_wood_defaults(), }) -mcl_doors:register_trapdoor("mcl_cherry_blossom:cherrytrapdoor", { +mcl_doors:register_trapdoor("mcl_cherry_blossom:cherry_trapdoor", { description = S("Cherry Trapdoor"), tile_front = "mcl_cherry_blossom_trapdoor.png", tile_side = "mcl_cherry_blossom_trapdoor_side.png", diff --git a/mods/ITEMS/mcl_dye/init.lua b/mods/ITEMS/mcl_dye/init.lua index 692cd5e87..abd6ed1d9 100644 --- a/mods/ITEMS/mcl_dye/init.lua +++ b/mods/ITEMS/mcl_dye/init.lua @@ -192,7 +192,11 @@ local function apply_bone_meal(pointed_thing, user) mcl_dye.add_bone_meal_particle(pos) -- Saplings: 45% chance to advance growth stage if math.random(1, 100) <= 45 then - return mcl_core.grow_sapling(pos, n) + if n.name == "mcl_cherry_blossom:cherrysapling" then + return mcl_cherry_blossom.generate_cherry_tree(pos) -- If cherry blossom sapling, run that callback instead. + else + return mcl_core.grow_sapling(pos, n) + end end elseif minetest.get_item_group(n.name, "mushroom") == 1 then mcl_dye.add_bone_meal_particle(pos)