From 4f8eeab19a08fec429e346bdcf451683f58d1662 Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Sun, 4 Sep 2022 07:15:25 +0100 Subject: [PATCH 1/7] fix flowerpot order --- flowers.lua | 8 ++++++++ init.lua | 8 -------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/flowers.lua b/flowers.lua index 8d5d5f2..eb83a16 100644 --- a/flowers.lua +++ b/flowers.lua @@ -115,3 +115,11 @@ minetest.register_decoration({ spawn_by = "group:water", num_spawn_by = 1 }) + +-- flowerpot mod +if minetest.get_modpath("flowerpot") then + flowerpot.register_node("bakedclay:delphinium") + flowerpot.register_node("bakedclay:thistle") + flowerpot.register_node("bakedclay:lazarus") + flowerpot.register_node("bakedclay:mannagrass") +end diff --git a/init.lua b/init.lua index 409a73c..4b5be62 100644 --- a/init.lua +++ b/init.lua @@ -212,14 +212,6 @@ if minetest.settings:get_bool("colored_clay_compatibility") == true then end end --- flowerpot mod -if minetest.get_modpath("flowerpot") then - flowerpot.register_node("bakedclay:delphinium") - flowerpot.register_node("bakedclay:thistle") - flowerpot.register_node("bakedclay:lazarus") - flowerpot.register_node("bakedclay:mannagrass") -end - -- get mod path local path = minetest.get_modpath("bakedclay") From a01222f15ea70e9b5c6af8c8debff1453d74e7cd Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Fri, 25 Nov 2022 09:29:21 +0000 Subject: [PATCH 2/7] add info to license.txt --- license.txt | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/license.txt b/license.txt index 532dbe2..18fff3e 100644 --- a/license.txt +++ b/license.txt @@ -21,8 +21,16 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -Textures by Amara2_MK (Creative Commons) +Textures by TenPlus1 (CC0) unless listed below + +Textures by Amara2_MK (CC0) https://www.curseforge.com/minecraft/texture-packs/glazed-terracotta-revamp baked_clay_terracotta*.png Missing gray, light gray, black and green textures re-coloured by Firefox. + +Textures by Timbits (CC-BY-SA 3.0) + baked_clay_lazarus.png + baked_clay_delphinium.png + baked_clay_mannagrass.png + baked_clay_thistle.png From 4af6f357340c095fe248e293d3ffa1cb7310d87b Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Mon, 28 Nov 2022 09:07:59 +0000 Subject: [PATCH 3/7] update license.txt --- license.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/license.txt b/license.txt index 18fff3e..9019798 100644 --- a/license.txt +++ b/license.txt @@ -23,7 +23,7 @@ THE SOFTWARE. Textures by TenPlus1 (CC0) unless listed below -Textures by Amara2_MK (CC0) +Textures by Amara2_MK (Creative Commons) https://www.curseforge.com/minecraft/texture-packs/glazed-terracotta-revamp baked_clay_terracotta*.png From ed06375ad55a43571d0666e2741a8af43177b91c Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Mon, 19 Dec 2022 11:23:17 +0000 Subject: [PATCH 4/7] remove technic_cnc dependency, register cnc nodes using minetest.after --- depends.txt | 1 - init.lua | 11 +++++++---- mod.conf | 2 +- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/depends.txt b/depends.txt index 2a83a65..c248394 100644 --- a/depends.txt +++ b/depends.txt @@ -2,5 +2,4 @@ default stairs moreblocks? lucky_block? -technic_cnc? flowerpot? diff --git a/init.lua b/init.lua index 4b5be62..18a3687 100644 --- a/init.lua +++ b/init.lua @@ -91,10 +91,13 @@ for _, clay in pairs(clay) do -- register bakedclay for use in technic_cnc mod if techcnc_mod then - technic_cnc.register_all("bakedclay:" .. clay[1], - {cracky = 3, not_in_creative_inventory = 1}, - {"baked_clay_" .. clay[1] .. ".png"}, - clay[2] .. " Baked Clay") + minetest.after(0.1, function() + + technic_cnc.register_all("bakedclay:" .. clay[1], + {cracky = 3, not_in_creative_inventory = 1}, + {"baked_clay_" .. clay[1] .. ".png"}, + clay[2] .. " Baked Clay") + end) end end diff --git a/mod.conf b/mod.conf index d6afa41..6aabb44 100644 --- a/mod.conf +++ b/mod.conf @@ -1,4 +1,4 @@ name = bakedclay depends = default -optional_depends = stairs, moreblocks, lucky_block, technic_cnc, flowerpot +optional_depends = stairs, moreblocks, lucky_block, flowerpot description = Adds the ability to bake clay into blocks and colour them with dye. From bd5ff73c19ebaeec305d1ef6e7c94846b1722510 Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Sat, 24 Dec 2022 08:28:37 +0000 Subject: [PATCH 5/7] remove 0.4.x support for better 5.x mod compatibility --- README.md | 1 + depends.txt | 5 ----- description.txt | 1 - flowers.lua | 5 ++++- init.lua | 19 +++++++++++-------- 5 files changed, 16 insertions(+), 15 deletions(-) delete mode 100644 depends.txt delete mode 100644 description.txt diff --git a/README.md b/README.md index 1cf146a..d9791c5 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ https://forum.minetest.net/viewtopic.php?id=8890 Changelog: +- 1.1 - Remove 0.4.x compatibility to better support 5.x mods - 1.0 - Re-Added glazed terracotta blocks when you cook baked clay in furnace (thanks Amara2_MK), added support for sofar's flowerpot mod, missing glazed textures re-coloured by firefox. - 0.9 - Baked clay now works in the technic cnc machine - 0.8 - Cooking clay block in furnace gives natural baked clay which you can dye diff --git a/depends.txt b/depends.txt deleted file mode 100644 index c248394..0000000 --- a/depends.txt +++ /dev/null @@ -1,5 +0,0 @@ -default -stairs -moreblocks? -lucky_block? -flowerpot? diff --git a/description.txt b/description.txt deleted file mode 100644 index b469a1b..0000000 --- a/description.txt +++ /dev/null @@ -1 +0,0 @@ -Adds the ability to bake clay into blocks and colour them with dye. \ No newline at end of file diff --git a/flowers.lua b/flowers.lua index eb83a16..3ac074f 100644 --- a/flowers.lua +++ b/flowers.lua @@ -1,3 +1,6 @@ +-- 5.x translation +S = minetest.get_translator("bakedclay") + local flowers = { {"delphinium", "Blue Delphinium", {-0.15, -0.5, -0.15, 0.15, 0.3, 0.15}, {color_cyan = 1}}, @@ -22,7 +25,7 @@ local function add_simple_flower(name, desc, box, f_groups) f_groups.attached_node = 1 minetest.register_node("bakedclay:" .. name, { - description = desc, + description = S(desc), drawtype = "plantlike", waving = 1, tiles = {"baked_clay_" .. name .. ".png"}, diff --git a/init.lua b/init.lua index 18a3687..c6cc3b4 100644 --- a/init.lua +++ b/init.lua @@ -1,6 +1,7 @@ +-- 5.x translation +S = minetest.get_translator("bakedclay") --- Baked Clay by TenPlus1 - +-- list of clay colours local clay = { {"natural", "Natural"}, {"white", "White"}, @@ -20,22 +21,24 @@ local clay = { {"dark_green", "Dark Green"} } +-- check mod support local techcnc_mod = minetest.get_modpath("technic_cnc") local stairs_mod = minetest.get_modpath("stairs") local stairsplus_mod = minetest.get_modpath("moreblocks") and minetest.global_exists("stairsplus") +-- scroll through colours for _, clay in pairs(clay) do - -- node + -- register node minetest.register_node("bakedclay:" .. clay[1], { - description = clay[2] .. " Baked Clay", + description = S(clay[2] .. " Baked Clay"), tiles = {"baked_clay_" .. clay[1] ..".png"}, groups = {cracky = 3, bakedclay = 1}, sounds = default.node_sound_stone_defaults() }) - -- craft recipe + -- register craft recipe if clay[1] ~= "natural" then minetest.register_craft({ @@ -88,10 +91,10 @@ for _, clay in pairs(clay) do default.node_sound_stone_defaults()) end - -- register bakedclay for use in technic_cnc mod + -- register bakedclay for use in technic_cnc mod after all mods loaded if techcnc_mod then - minetest.after(0.1, function() + core.register_on_mods_loaded(function() technic_cnc.register_all("bakedclay:" .. clay[1], {cracky = 3, not_in_creative_inventory = 1}, @@ -109,7 +112,7 @@ for _, clay in pairs(clay) do local texture = "baked_clay_terracotta_" .. clay[1] ..".png" minetest.register_node("bakedclay:terracotta_" .. clay[1], { - description = clay[2] .. " Glazed Terracotta", + description = S(clay[2] .. " Glazed Terracotta"), tiles = { texture .. "", texture .. "", From 2e3e82cd92e573cdfadfe4ec7a04320d717c9b0d Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Wed, 15 Mar 2023 07:47:46 +0000 Subject: [PATCH 6/7] add 'stairsplus_clay_compatibility' setting --- README.md | 3 +++ init.lua | 17 +++++++++++------ settingtypes.txt | 3 +++ 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index d9791c5..1798395 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ https://forum.minetest.net/viewtopic.php?id=8890 Changelog: +- 1.2 - Add 'stairsplus_clay_compatibility' setting. - 1.1 - Remove 0.4.x compatibility to better support 5.x mods - 1.0 - Re-Added glazed terracotta blocks when you cook baked clay in furnace (thanks Amara2_MK), added support for sofar's flowerpot mod, missing glazed textures re-coloured by firefox. - 0.9 - Baked clay now works in the technic cnc machine @@ -24,3 +25,5 @@ Lucky Blocks: 10 Note: Under settings you will find 'colored_clay_compatibility' switch that when enabled will register aliases for the older colored clay mod and it's stairplus stairs. + +You will also find the 'stairsplus_clay_compatibility' setting that is enabled by default for older worlds that switched from default stairs mod to stairsplus. It can be disabled for brand new worlds only using stairsplus mod though. diff --git a/init.lua b/init.lua index c6cc3b4..ec68049 100644 --- a/init.lua +++ b/init.lua @@ -26,6 +26,8 @@ local techcnc_mod = minetest.get_modpath("technic_cnc") local stairs_mod = minetest.get_modpath("stairs") local stairsplus_mod = minetest.get_modpath("moreblocks") and minetest.global_exists("stairsplus") +local stairsplus_compat = minetest.settings:get_bool("stairsplus_clay_compatibility") ~= false + -- scroll through colours for _, clay in pairs(clay) do @@ -62,14 +64,17 @@ for _, clay in pairs(clay) do sounds = default.node_sound_stone_defaults() }) - stairsplus:register_alias_all("bakedclay", clay[1], - "bakedclay", "baked_clay_" .. clay[1]) + if stairsplus_compat then - minetest.register_alias("stairs:slab_bakedclay_".. clay[1], - "bakedclay:slab_baked_clay_" .. clay[1]) + stairsplus:register_alias_all("bakedclay", clay[1], + "bakedclay", "baked_clay_" .. clay[1]) - minetest.register_alias("stairs:stair_bakedclay_".. clay[1], - "bakedclay:stair_baked_clay_" .. clay[1]) + minetest.register_alias("stairs:slab_bakedclay_".. clay[1], + "bakedclay:slab_baked_clay_" .. clay[1]) + + minetest.register_alias("stairs:stair_bakedclay_".. clay[1], + "bakedclay:stair_baked_clay_" .. clay[1]) + end -- stairs redo elseif stairs_mod and stairs.mod then diff --git a/settingtypes.txt b/settingtypes.txt index bdd2a13..657f965 100644 --- a/settingtypes.txt +++ b/settingtypes.txt @@ -1,2 +1,5 @@ # Registers compatibility aliases with the older colored_clay mod colored_clay_compatibility (Colored Clay Compatibility) bool false + +# Registers compatibility aliases in older worlds for StairsPlus mod +stairsplus_clay_compatibility (StairsPlus Stair Compatibility) bool true From 720adef1d08a1d502dd4ef6842c1ac6600162f36 Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Thu, 13 Apr 2023 17:30:35 +0100 Subject: [PATCH 7/7] remove stack_max limit of 99 for [game] to handle instead. --- flowers.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flowers.lua b/flowers.lua index 3ac074f..0bdeea7 100644 --- a/flowers.lua +++ b/flowers.lua @@ -35,7 +35,7 @@ local function add_simple_flower(name, desc, box, f_groups) paramtype = "light", walkable = false, buildable_to = true, - stack_max = 99, +-- stack_max = 99, groups = f_groups, sounds = default.node_sound_leaves_defaults(), selection_box = {type = "fixed", fixed = box}