From 23d04af7d6c5cec74cc5f40b3c2ef951a6c7a84e Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Sun, 9 Jul 2023 15:14:43 -0400 Subject: [PATCH 01/25] remove biomelib dep from cavestuff (#42) Co-authored-by: Niklp09 <89982526+Niklp09@users.noreply.github.com> --- cavestuff/mapgen.lua | 90 ++++++++++++++++++++++++++++---------------- cavestuff/mod.conf | 2 +- 2 files changed, 59 insertions(+), 33 deletions(-) diff --git a/cavestuff/mapgen.lua b/cavestuff/mapgen.lua index 92989bc..64de328 100644 --- a/cavestuff/mapgen.lua +++ b/cavestuff/mapgen.lua @@ -1,39 +1,65 @@ --Map Generation Stuff -biome_lib.register_on_generate( - { - surface = { - "default:dirt_with_grass", - "default:gravel", - "default:stone", - "default:permafrost_with_stones" - }, - max_count = 50, - rarity = 0, - plantlife_limit = -1, - check_air = true, - random_facedir = {0, 3} - }, - { +minetest.register_decoration({ + decoration = { "cavestuff:pebble_1", "cavestuff:pebble_2" - } -) - -biome_lib.register_on_generate( - { - surface = { - "default:desert_sand", - "default:desert_stone" - }, - max_count = 50, - rarity = 0, - plantlife_limit = -1, - check_air = true, - random_facedir = {0, 3} }, - { + place_on = { + "default:dirt_with_grass", + "default:gravel", + "default:stone", + "default:permafrost_with_stones" + }, + noise_params = { + offset = 0, + scale = 0.0078125, + spread = { + y = 100, + z = 100, + x = 100 + }, + seed = 0, + octaves = 3, + persist = 0.6, + flags = "absvalue", + lacunarity = 2 + }, + param2 = 0, + flags = "all_floors", + deco_type = "simple", + param2_max = 3, + y_min = -16, + y_max = 48 +}) + +minetest.register_decoration({ + decoration = { "cavestuff:desert_pebble_1", "cavestuff:desert_pebble_2" - } -) + }, + place_on = { + "default:desert_sand", + "default:desert_stone" + }, + noise_params = { + offset = 0, + scale = 0.0078125, + spread = { + y = 100, + z = 100, + x = 100 + }, + seed = 0, + octaves = 3, + persist = 0.6, + flags = "absvalue", + lacunarity = 2 + }, + param2 = 0, + flags = "all_floors", + deco_type = "simple", + param2_max = 3, + y_min = -16, + y_max = 48 +}) \ No newline at end of file diff --git a/cavestuff/mod.conf b/cavestuff/mod.conf index 55cdcab..b021c9e 100644 --- a/cavestuff/mod.conf +++ b/cavestuff/mod.conf @@ -1,2 +1,2 @@ name = cavestuff -depends = default,biome_lib +depends = default From c6b1ce5ca58a0c3f72c66bc4250a20e23b22af0b Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Sun, 9 Jul 2023 15:52:04 -0400 Subject: [PATCH 02/25] remove biome lib usage from molehills (#43) --- molehills/init.lua | 46 ++++++++++++-------------------------- molehills/mod.conf | 2 +- molehills/settingtypes.txt | 8 ------- 3 files changed, 15 insertions(+), 41 deletions(-) delete mode 100644 molehills/settingtypes.txt diff --git a/molehills/init.lua b/molehills/init.lua index aba3d41..047d749 100644 --- a/molehills/init.lua +++ b/molehills/init.lua @@ -2,13 +2,6 @@ -- Idea by Sokomine -- Code & textures by Mossmanikin -abstract_molehills = {} - -local molehills_rarity = tonumber(minetest.settings:get("molehills_rarity")) or 99.5 -local molehills_rarity_fertility = tonumber(minetest.settings:get("molehills_rarity_fertility")) or 1 -local molehills_fertility = tonumber(minetest.settings:get("molehills_fertility")) or -0.6 - - -- support for i18n local S = minetest.get_translator("molehills") ----------------------------------------------------------------------------------------------- @@ -48,29 +41,18 @@ minetest.register_craft({ -- molehills --> dirt ----------------------------------------------------------------------------------------------- -- GeNeRaTiNG ----------------------------------------------------------------------------------------------- -abstract_molehills.place_molehill = function(pos) - local right_here = {x=pos.x , y=pos.y+1, z=pos.z } - if minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }).name ~= "air" - and minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }).name ~= "air" - and minetest.get_node({x=pos.x , y=pos.y, z=pos.z+1}).name ~= "air" - and minetest.get_node({x=pos.x , y=pos.y, z=pos.z-1}).name ~= "air" - and minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z+1}).name ~= "air" - and minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z-1}).name ~= "air" - and minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z+1}).name ~= "air" - and minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z-1}).name ~= "air" then - minetest.swap_node(right_here, {name="molehills:molehill"}) - end -end - -biome_lib.register_on_generate({ - surface = {"default:dirt_with_grass"}, - rarity = molehills_rarity, - rarity_fertility = molehills_rarity_fertility, - plantlife_limit = molehills_fertility, - min_elevation = 1, - max_elevation = 40, - avoid_nodes = {"group:tree","group:liquid","group:stone","group:falling_node"--[[,"air"]]}, - avoid_radius = 4, +minetest.register_decoration({ + decoration = { + "molehills:molehill" }, - abstract_molehills.place_molehill -) + fill_ratio = 0.002, + y_min = 1, + y_max = 40, + place_on = { + "default:dirt_with_grass" + }, + spawn_by = "air", + num_spawn_by = 1, + deco_type = "simple", + flags = "all_floors", +}) diff --git a/molehills/mod.conf b/molehills/mod.conf index d929679..ef391f9 100644 --- a/molehills/mod.conf +++ b/molehills/mod.conf @@ -1,2 +1,2 @@ name = molehills -depends = default, biome_lib +depends = default diff --git a/molehills/settingtypes.txt b/molehills/settingtypes.txt deleted file mode 100644 index a10276a..0000000 --- a/molehills/settingtypes.txt +++ /dev/null @@ -1,8 +0,0 @@ -#Molehills rarity % -molehills_rarity (Molehills rarity %) float 99.5 0 100 - -#How much the rarity is reduced by fertility % -molehills_rarity_fertility (Molehills rarity fertility reduction %) float 1 0 100 - -#Molehills minimum fertility (-1 to +1) -molehills_fertility (Molehills minimum fertility) float -0.6 -1 1 From d483c2a1ae0e5c58616233df8071b532cad60612 Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Sun, 9 Jul 2023 15:55:06 -0400 Subject: [PATCH 03/25] bump the number of spawnby in molehills decoration registration --- molehills/init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/molehills/init.lua b/molehills/init.lua index 047d749..c682318 100644 --- a/molehills/init.lua +++ b/molehills/init.lua @@ -52,7 +52,7 @@ minetest.register_decoration({ "default:dirt_with_grass" }, spawn_by = "air", - num_spawn_by = 1, + num_spawn_by = 3, deco_type = "simple", flags = "all_floors", }) From d9782771c3511d822fb8eedccbbe7e86f43d9167 Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Sun, 9 Jul 2023 16:14:45 -0400 Subject: [PATCH 04/25] remove biomelib usage from sunflowers (#44) --- pl_sunflowers/init.lua | 29 ++++++++++++++--------------- pl_sunflowers/mod.conf | 1 - 2 files changed, 14 insertions(+), 16 deletions(-) diff --git a/pl_sunflowers/init.lua b/pl_sunflowers/init.lua index 6416790..c7aaec8 100644 --- a/pl_sunflowers/init.lua +++ b/pl_sunflowers/init.lua @@ -1,10 +1,6 @@ -- support for i18n local S = minetest.get_translator("pl_sunflowers") -local sunflowers_max_count = tonumber(minetest.settings:get("pl_sunflowers_max_count")) or 10 -local sunflowers_rarity = tonumber(minetest.settings:get("pl_sunflowers_rarity")) or 25 - - local box = { type="fixed", fixed = { { -0.2, -0.5, -0.2, 0.2, 0.5, 0.2 } }, @@ -40,17 +36,20 @@ minetest.register_node(":flowers:sunflower", { } }) -biome_lib.register_on_generate({ - surface = {"default:dirt_with_grass"}, - avoid_nodes = { "flowers:sunflower" }, - max_count = sunflowers_max_count, - rarity = sunflowers_rarity, - min_elevation = 0, - plantlife_limit = -0.9, - temp_max = -0.1, - random_facedir = {0,3}, +minetest.register_decoration({ + decoration = { + "flowers:sunflower" }, - "flowers:sunflower" -) + fill_ratio = 0.005, + y_min = 1, + y_max = 40, + param2 = 0, + param2_max = 3, + place_on = { + "default:dirt_with_grass" + }, + deco_type = "simple", + flags = "all_floors", +}) minetest.register_alias("sunflower:sunflower", "flowers:sunflower") diff --git a/pl_sunflowers/mod.conf b/pl_sunflowers/mod.conf index 1332723..238079e 100644 --- a/pl_sunflowers/mod.conf +++ b/pl_sunflowers/mod.conf @@ -1,3 +1,2 @@ name = pl_sunflowers -depends = biome_lib optional_depends = farming, flowers From c7f65aac83f4e99e0bdc5d242084609d660c894c Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Tue, 11 Jul 2023 00:24:25 +0200 Subject: [PATCH 05/25] cleanup codebase (#46) * cleanup codebase * fix typo * add nil checks to on_place * nuke all mod loaded statements --- 3dmushrooms/init.lua | 7 --- 3dmushrooms/locale/3dmushrooms.de.tr | 8 ---- 3dmushrooms/locale/3dmushrooms.eo.tr | 8 ---- 3dmushrooms/locale/template.txt | 8 ---- 3dmushrooms/mod.conf | 2 +- bushes/init.lua | 15 +++---- bushes/locale/bushes.de.tr | 6 --- bushes/locale/bushes.eo.tr | 6 --- bushes/locale/bushes.fr.tr | 7 --- bushes/locale/template.txt | 6 --- bushes_classic/cooking.lua | 5 ++- bushes_classic/init.lua | 4 +- bushes_classic/locale/bushes_classic.de.tr | 45 ++++++++----------- bushes_classic/locale/bushes_classic.eo.tr | 47 +++++++++----------- bushes_classic/locale/bushes_classic.es.tr | 45 ++++++++----------- bushes_classic/locale/bushes_classic.fr.tr | 45 ++++++++----------- bushes_classic/locale/bushes_classic.tr.tr | 45 ++++++++----------- bushes_classic/locale/template.txt | 45 ++++++++----------- bushes_classic/nodes.lua | 8 +--- cavestuff/init.lua | 15 ------- cavestuff/locale/cavestuff.de.tr | 7 --- cavestuff/locale/cavestuff.eo.tr | 7 --- cavestuff/locale/cavestuff.fr.tr | 7 --- cavestuff/locale/template.txt | 7 --- cavestuff/nodes.lua | 27 ++++++------ dryplants/crafting.lua | 4 +- dryplants/init.lua | 15 ++----- dryplants/juncus.lua | 4 ++ dryplants/locale/dryplants.de.tr | 7 --- dryplants/locale/dryplants.eo.tr | 7 --- dryplants/locale/dryplants.fr.tr | 7 --- dryplants/locale/template.txt | 7 --- ferns/crafting.lua | 6 +-- ferns/gianttreefern.lua | 4 +- ferns/init.lua | 50 ---------------------- ferns/locale/ferns.de.tr | 10 +---- ferns/locale/ferns.eo.tr | 10 +---- ferns/locale/ferns.fr.tr | 9 +--- ferns/locale/template.txt | 10 +---- molehills/init.lua | 13 ++---- molehills/locale/molehills.de.tr | 7 --- molehills/locale/molehills.eo.tr | 7 --- molehills/locale/molehills.fr.tr | 7 --- molehills/locale/template.txt | 7 --- nature_classic/global_function.lua | 4 +- nature_classic/init.lua | 10 +---- nature_classic/locale/nature_classic.de.tr | 8 ---- nature_classic/locale/nature_classic.fr.tr | 8 ---- nature_classic/locale/template.txt | 8 ---- pl_seaweed/init.lua | 18 +++++--- pl_seaweed/locale/pl_seaweed.de.tr | 9 ---- pl_seaweed/locale/pl_seaweed.fr.tr | 8 ---- pl_seaweed/locale/pl_seaweed.tr.tr | 8 ---- pl_seaweed/locale/pl_seawood.eo.tr | 9 ---- pl_seaweed/locale/pl_seawood.es.tr | 8 ---- pl_seaweed/locale/template.txt | 9 ---- pl_sunflowers/locale/pl_sunflowers.de.tr | 9 ---- pl_sunflowers/locale/pl_sunflowers.eo.tr | 9 ---- pl_sunflowers/locale/pl_sunflowers.es.tr | 8 ---- pl_sunflowers/locale/pl_sunflowers.fr.tr | 8 ---- pl_sunflowers/locale/pl_sunflowers.tr.tr | 8 ---- pl_sunflowers/locale/template.txt | 9 ---- pl_waterlilies/init.lua | 17 +++++--- pl_waterlilies/locale/pl_waterlilies.de.tr | 9 ---- pl_waterlilies/locale/pl_waterlilies.eo.tr | 11 +---- pl_waterlilies/locale/pl_waterlilies.es.tr | 8 ---- pl_waterlilies/locale/pl_waterlilies.fr.tr | 8 ---- pl_waterlilies/locale/pl_waterlilies.tr.tr | 8 ---- pl_waterlilies/locale/template.txt | 11 +---- poisonivy/init.lua | 5 +-- poisonivy/locale/poisonivy.de.tr | 8 ---- poisonivy/locale/poisonivy.eo.tr | 8 ---- poisonivy/locale/poisonivy.es.tr | 8 ---- poisonivy/locale/poisonivy.fr.tr | 8 ---- poisonivy/locale/poisonivy.pt.tr | 8 ---- poisonivy/locale/poisonivy.pt_BR.tr | 8 ++-- poisonivy/locale/poisonivy.tr.tr | 8 ---- poisonivy/locale/template.txt | 4 ++ trunks/generating.lua | 2 - trunks/init.lua | 12 ------ trunks/locale/template.txt | 7 --- trunks/locale/trunks.de.tr | 7 --- trunks/locale/trunks.eo.tr | 7 --- trunks/locale/trunks.fr.tr | 7 --- trunks/nodes.lua | 8 ++-- vines/locale/template.txt | 6 --- vines/locale/vines.de.tr | 6 --- vines/locale/vines.eo.tr | 6 --- vines/locale/vines.fr.tr | 7 --- woodsoils/init.lua | 28 ------------ woodsoils/locale/template.txt | 7 --- woodsoils/locale/woodsoils.de.tr | 7 --- woodsoils/locale/woodsoils.eo.tr | 7 --- woodsoils/locale/woodsoils.fr.tr | 7 --- youngtrees/locale/template.txt | 7 --- youngtrees/locale/youngtrees.de.tr | 7 --- youngtrees/locale/youngtrees.eo.tr | 7 --- youngtrees/locale/youngtrees.fr.tr | 7 --- 98 files changed, 200 insertions(+), 877 deletions(-) delete mode 100644 3dmushrooms/locale/3dmushrooms.de.tr delete mode 100644 3dmushrooms/locale/3dmushrooms.eo.tr delete mode 100644 3dmushrooms/locale/template.txt create mode 100644 poisonivy/locale/template.txt diff --git a/3dmushrooms/init.lua b/3dmushrooms/init.lua index f4bfbcb..170a0da 100644 --- a/3dmushrooms/init.lua +++ b/3dmushrooms/init.lua @@ -1,10 +1,5 @@ -- 3D Mushroom mod by VanessaE -mushroom = {} - --- support for i18n -local S = minetest.get_translator("3dmushrooms") - minetest.override_item("flowers:mushroom_fertile_brown", { drawtype = "mesh", mesh = "3dmushrooms.obj", @@ -68,5 +63,3 @@ minetest.register_alias("mushroom:spore1", "flowers:mushroom_spores_red") minetest.register_alias("mushroom:poison", "flowers:mushroom_red") minetest.register_alias("mushroom:identifier", "default:mese_crystal_fragment") - -minetest.log("info", S("[3D Mushrooms] loaded.")) diff --git a/3dmushrooms/locale/3dmushrooms.de.tr b/3dmushrooms/locale/3dmushrooms.de.tr deleted file mode 100644 index 9360f2b..0000000 --- a/3dmushrooms/locale/3dmushrooms.de.tr +++ /dev/null @@ -1,8 +0,0 @@ -# textdomain: 3dmushrooms - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. - -[3D Mushrooms] loaded.=[3D Mushrooms] geladen. diff --git a/3dmushrooms/locale/3dmushrooms.eo.tr b/3dmushrooms/locale/3dmushrooms.eo.tr deleted file mode 100644 index f586e47..0000000 --- a/3dmushrooms/locale/3dmushrooms.eo.tr +++ /dev/null @@ -1,8 +0,0 @@ -# textdomain: 3dmushrooms - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. - -[3D Mushrooms] loaded.=[3D Mushrooms] ŝargis. diff --git a/3dmushrooms/locale/template.txt b/3dmushrooms/locale/template.txt deleted file mode 100644 index e56ec01..0000000 --- a/3dmushrooms/locale/template.txt +++ /dev/null @@ -1,8 +0,0 @@ -# textdomain: 3dmushrooms - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. - -[3D Mushrooms] loaded.= diff --git a/3dmushrooms/mod.conf b/3dmushrooms/mod.conf index 27d9684..d7b881e 100644 --- a/3dmushrooms/mod.conf +++ b/3dmushrooms/mod.conf @@ -1,2 +1,2 @@ name = 3dmushrooms -depends = default, flowers +depends = flowers diff --git a/bushes/init.lua b/bushes/init.lua index a24812e..f541259 100644 --- a/bushes/init.lua +++ b/bushes/init.lua @@ -31,7 +31,6 @@ minetest.register_node("bushes:youngtree2_bottom", { node_box = { type = "fixed", fixed = { - --{0.375000,-0.500000,-0.500000,0.500000,0.500000,-0.375000}, --NodeBox 1 {-0.0612,-0.500000,-0.500000,0.0612,0.500000,-0.375000}, --NodeBox 1 } }, @@ -40,10 +39,10 @@ minetest.register_node("bushes:youngtree2_bottom", { drop = 'default:stick' }) -local BushBranchCenter = { {1,1}, {3,2} } +local BushBranchCenter = { {1,1}, {3,2} } for i in pairs(BushBranchCenter) do - local Num = BushBranchCenter[i][1] - local TexNum = BushBranchCenter[i][2] + local Num = BushBranchCenter[i][1] + local TexNum = BushBranchCenter[i][2] minetest.register_node("bushes:bushbranches"..Num, { description = S("Bush Branches @1", Num), drawtype = "nodebox", @@ -79,10 +78,10 @@ for i in pairs(BushBranchCenter) do }) end -local BushBranchSide = { {2,1}, {4,2} } +local BushBranchSide = { {2,1}, {4,2} } for i in pairs(BushBranchSide) do - local Num = BushBranchSide[i][1] - local TexNum = BushBranchSide[i][2] + local Num = BushBranchSide[i][1] + local TexNum = BushBranchSide[i][2] minetest.register_node("bushes:bushbranches"..Num, { description = S("Bush Branches @1", Num), drawtype = "nodebox", @@ -124,7 +123,7 @@ for i in pairs(BushBranchSide) do }) end -local BushLeafNode = { {1}, {2}} +local BushLeafNode = { {1}, {2}} for i in pairs(BushLeafNode) do local Num = BushLeafNode[i][1] minetest.register_node("bushes:BushLeaves"..Num, { diff --git a/bushes/locale/bushes.de.tr b/bushes/locale/bushes.de.tr index 6649b1f..af63ead 100644 --- a/bushes/locale/bushes.de.tr +++ b/bushes/locale/bushes.de.tr @@ -1,10 +1,4 @@ # textdomain: bushes - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. - Young Tree 2 (bottom)=Strauch 2 (Ansatz) Bush Branches @1=Buschäste @1 Bush Leaves @1=Buschblätter @1 diff --git a/bushes/locale/bushes.eo.tr b/bushes/locale/bushes.eo.tr index 5ff623a..95ef7ab 100644 --- a/bushes/locale/bushes.eo.tr +++ b/bushes/locale/bushes.eo.tr @@ -1,10 +1,4 @@ # textdomain: bushes - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. - Young Tree 2 (bottom)=Juna Arbo 2 (malsupro) Bush Branches @1=Arbustaj Branĉoj @1 Bush Leaves @1=Arbustaj Folioj @1 diff --git a/bushes/locale/bushes.fr.tr b/bushes/locale/bushes.fr.tr index a338814..6289a52 100644 --- a/bushes/locale/bushes.fr.tr +++ b/bushes/locale/bushes.fr.tr @@ -1,11 +1,4 @@ # textdomain: bushes - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Young Tree 2 (bottom)=Arbuste 2 (bas) Bush Branches @1=Branches de buisson @1 Bush Leaves @1=Feuilles de buisson @1 diff --git a/bushes/locale/template.txt b/bushes/locale/template.txt index e3db363..412fb60 100644 --- a/bushes/locale/template.txt +++ b/bushes/locale/template.txt @@ -1,10 +1,4 @@ # textdomain: bushes - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. - Young Tree 2 (bottom)= Bush Branches @1= Bush Leaves @1= diff --git a/bushes_classic/cooking.lua b/bushes_classic/cooking.lua index 3e46441..9179f11 100644 --- a/bushes_classic/cooking.lua +++ b/bushes_classic/cooking.lua @@ -33,9 +33,12 @@ end -- override farming_plus strawberry and add food_ group if minetest.get_modpath("farming_plus") then + local groups = table.copy(minetest.registered_items["farming_plus:strawberry_item"]) + groups["food_strawberry"] = 1 + groups["food_berry"] = 1 minetest.override_item("farming_plus:strawberry_item", { - groups = {food_strawberry = 1, food_berry = 1, flammable = 2}, + groups = groups, }) end diff --git a/bushes_classic/init.lua b/bushes_classic/init.lua index a470a8f..ff386cb 100644 --- a/bushes_classic/init.lua +++ b/bushes_classic/init.lua @@ -7,7 +7,7 @@ bushes_classic = {} local S = minetest.get_translator("bushes_classic") bushes_classic.bushes = { - "strawberry", + "strawberry", "blackberry", "blueberry", "raspberry", @@ -54,5 +54,3 @@ biome_lib.register_active_spawner({ }) minetest.register_alias("bushes:basket_pies", "bushes:basket_strawberry") - -print("[Bushes] Loaded.") diff --git a/bushes_classic/locale/bushes_classic.de.tr b/bushes_classic/locale/bushes_classic.de.tr index 35520b5..9d45852 100644 --- a/bushes_classic/locale/bushes_classic.de.tr +++ b/bushes_classic/locale/bushes_classic.de.tr @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Xanthin, 2017. -# - Sugar=Zucker -Basket with Strawberry pies=Korb mit Erdbeertorten -Cooked Strawberry pie=Erdbeertorte -Raw Strawberry pie=Rohe Erdbeertorte -Slice of Strawberry pie=Erdbeertortenstueck Strawberry=Erdbeere +Raw Strawberry pie=Rohe Erdbeertorte +Cooked Strawberry pie=Erdbeertorte +Slice of Strawberry pie=Erdbeertortenstueck +Basket with Strawberry pies=Korb mit Erdbeertorten Strawberry Bush=Erdbeerbusch -Basket with Blackberry pies=Korb mit Brombeertorten Blackberry=Brombeere -Blackberry Bush=Brombeerbusch -Cooked Blackberry pie=Brombeertorte Raw Blackberry pie=Rohe Brombeertorte +Cooked Blackberry pie=Brombeertorte Slice of Blackberry pie=Brombeertortenstueck -Basket with Blueberry pies=Korb mit Blaubeertorten +Basket with Blackberry pies=Korb mit Brombeertorten +Blackberry Bush=Brombeerbusch Blueberry=Blaubeere -Blueberry Bush=Blaubeerbusch -Cooked Blueberry pie=Blaubeertorte Raw Blueberry pie=Rohe Blaubeertorte +Cooked Blueberry pie=Blaubeertorte Slice of Blueberry pie=Blaubeertortenstueck -Basket with Raspberry pies=Korb mit Himbeertorten -Cooked Raspberry pie=Himbeertorte +Basket with Blueberry pies=Korb mit Blaubeertorten +Blueberry Bush=Blaubeerbusch Raspberry=Himbeere -Raspberry Bush=Himbeerbusch Raw Raspberry pie=Rohe Himbeertorte +Cooked Raspberry pie=Himbeertorte Slice of Raspberry pie=Himbeertortenstueck -Basket with Gooseberry pies=Korb mit Stachelbeertorten -Cooked Gooseberry pie=Stachelbeertorte +Basket with Raspberry pies=Korb mit Himbeertorten +Raspberry Bush=Himbeerbusch Gooseberry=Stachelbeere -Gooseberry Bush=Stachelbeerbusch Raw Gooseberry pie=Rohe Stachelbeertorte +Cooked Gooseberry pie=Stachelbeertorte Slice of Gooseberry pie=Stachelbeertortenstueck -Basket with Mixed Berry pies=Korb mit Beerenmixtorten -Cooked Mixed Berry pie=Beerenmixtorte -Currently fruitless Bush=zur Zeit fruechteloser +Basket with Gooseberry pies=Korb mit Stachelbeertorten +Gooseberry Bush=Stachelbeerbusch Mixed Berry=Beerenmix Raw Mixed Berry pie=Rohe Beerenmixtorte +Cooked Mixed Berry pie=Beerenmixtorte Slice of Mixed Berry pie=Beerenmixtortenstueck +Basket with Mixed Berry pies=Korb mit Beerenmixtorten +Currently fruitless Bush=zur Zeit fruechteloser Basket=Korb diff --git a/bushes_classic/locale/bushes_classic.eo.tr b/bushes_classic/locale/bushes_classic.eo.tr index af14e8b..194cc17 100644 --- a/bushes_classic/locale/bushes_classic.eo.tr +++ b/bushes_classic/locale/bushes_classic.eo.tr @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Sugar=Sukero -Basket with Strawberry pies=Korbo kun Fragokukoj -Cooked Strawberry pie=Kuirita Fragokuko -Raw Strawberry pie=Kruda Fragokuko -Slice of Strawberry pie=Tranĉaĵo de Fragokuko Strawberry=Frago +Raw Strawberry pie=Kruda Fragokuko +Cooked Strawberry pie=Kuirita Fragokuko +Slice of Strawberry pie=Tranĉaĵo de Fragokuko +Basket with Strawberry pies=Korbo kun Fragokukoj Strawberry Bush=Fraga Arbusto -Basket with Blackberry pies=Korbo kun Rubusokukoj -Cooked Blackberry pie=Kuirita Rubusokuko -Raw Blackberry pie=Kruda Rubusokuko -Slice of Blackberry pie=Tranĉaĵo de Rubusokuko Blackberry=Rubuso +Raw Blackberry pie=Kruda Rubusokuko +Cooked Blackberry pie=Kuirita Rubusokuko +Slice of Blackberry pie=Tranĉaĵo de Rubusokuko +Basket with Blackberry pies=Korbo kun Rubusokukoj Blackberry Bush=Rubusa Arbusto -Basket with Blueberry pies=Korbo kun Mirtelokukoj Blueberry=Mirtelo -Blueberry Bush=Mirtela Arbusto -Cooked Blueberry pie=Kuirita Mirtelokuko Raw Blueberry pie=Kruda Mirtelokuko +Cooked Blueberry pie=Kuirita Mirtelokuko Slice of Blueberry pie=Tranĉaĵo de Mirtelokuko -Basket with Raspberry pies=Korbo kun Frambokukoj -Cooked Raspberry pie=Kuirita Frambokuko +Basket with Blueberry pies=Korbo kun Mirtelokukoj +Blueberry Bush=Mirtela Arbusto Raspberry=Frambo -Raspberry Bush=Framba Arbusto Raw Raspberry pie=Kruda Frambokuko +Cooked Raspberry pie=Kuirita Frambokuko Slice of Raspberry pie=Tranĉaĵo de Frambokuko -Basket with Gooseberry pies=Korbo kun Grosberkuko -Cooked Gooseberry pie=Kuirita Grosberkuko +Basket with Raspberry pies=Korbo kun Frambokukoj +Raspberry Bush=Framba Arbusto Gooseberry=Grosbero -Gooseberry Bush=Grosberarbusto Raw Gooseberry pie=Kruda Grosberkuko +Cooked Gooseberry pie=Kuirita Grosberkuko Slice of Gooseberry pie=Tranĉaĵo de Grosberkuko -Basket with Mixed Berry pies=Korbo kun Miksitaj Beraj Kukoj -Cooked Mixed Berry pie=Kuirita Miksa Beraj Kukoj -Currently fruitless Bush=Nuntempe senfrukta Arbusto +Basket with Gooseberry pies=Korbo kun Grosberkuko +Gooseberry Bush=Grosberarbusto Mixed Berry=Miksita Bero Raw Mixed Berry pie=Kruda Miksita Bera Kuko +Cooked Mixed Berry pie=Kuirita Miksa Beraj Kukoj Slice of Mixed Berry pie=Tranĉaĵo de Miksita Bera Kuko +Basket with Mixed Berry pies=Korbo kun Miksitaj Beraj Kukoj +Currently fruitless Bush=Nuntempe senfrukta Arbusto Basket=Korbo diff --git a/bushes_classic/locale/bushes_classic.es.tr b/bushes_classic/locale/bushes_classic.es.tr index 9726073..2a900bc 100644 --- a/bushes_classic/locale/bushes_classic.es.tr +++ b/bushes_classic/locale/bushes_classic.es.tr @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Carlos Barraza , 2017. -# - Sugar=Azúcar -Basket with Strawberry pies=Cesta con Pasteles de Frutilla -Cooked Strawberry pie=Pastel de Frutilla Cocido -Raw Strawberry pie=Pastel de Frutilla Crudo -Slice of Strawberry pie=Rebanada de Pastel de Frutilla Strawberry=Frutilla +Raw Strawberry pie=Pastel de Frutilla Crudo +Cooked Strawberry pie=Pastel de Frutilla Cocido +Slice of Strawberry pie=Rebanada de Pastel de Frutilla +Basket with Strawberry pies=Cesta con Pasteles de Frutilla Strawberry Bush=Arbusto de Frutilla -Basket with Blackberry pies=Cesta con Pasteles de Mora Blackberry=Mora -Blackberry Bush=Arbusto de Mora -Cooked Blackberry pie=Pastel de Mora Cocido Raw Blackberry pie=Pastel de Mora Crudo +Cooked Blackberry pie=Pastel de Mora Cocido Slice of Blackberry pie=Rebanada de Pastel de Mora -Basket with Blueberry pies=Cesta con Pasteles de Arándano +Basket with Blackberry pies=Cesta con Pasteles de Mora +Blackberry Bush=Arbusto de Mora Blueberry=Arándano -Blueberry Bush=Arbusto de Arándano -Cooked Blueberry pie=Pastel de Arándano Cocido Raw Blueberry pie=Pastel de Arándano Crudo +Cooked Blueberry pie=Pastel de Arándano Cocido Slice of Blueberry pie=Rebanada de Pastel de Arándano -Basket with Raspberry pies=Cesta con Pasteles de Frambuesa -Cooked Raspberry pie=Pastel de Frambuesa Cocido +Basket with Blueberry pies=Cesta con Pasteles de Arándano +Blueberry Bush=Arbusto de Arándano Raspberry=Frambuesa -Raspberry Bush=Arbusto de Frambuesa Raw Raspberry pie=Pastel de Frambuesa Crudo +Cooked Raspberry pie=Pastel de Frambuesa Cocido Slice of Raspberry pie=Rebanada de Pastel de Frambuesa -Basket with Gooseberry pies=Cesta con Pasteles de Grosella -Cooked Gooseberry pie=Pastel de Grosella Cocido +Basket with Raspberry pies=Cesta con Pasteles de Frambuesa +Raspberry Bush=Arbusto de Frambuesa Gooseberry=Grosella -Gooseberry Bush=Arbusto de Grosella Raw Gooseberry pie=Pastel de Grosella Crudo +Cooked Gooseberry pie=Pastel de Grosella Cocido Slice of Gooseberry pie=Rebanada de Pastel de Grosella -Basket with Mixed Berry pies=Cesta con Pasteles de Mezcla de Baya -Cooked Mixed Berry pie=Pastel de Mezcla de Bayas Cocido -Currently fruitless Bush=Arbusto actualmente infructuoso +Basket with Gooseberry pies=Cesta con Pasteles de Grosella +Gooseberry Bush=Arbusto de Grosella Mixed Berry=Mezcla de Baya Raw Mixed Berry pie=Pastel de Mezcla de Bayas Cruda +Cooked Mixed Berry pie=Pastel de Mezcla de Bayas Cocido Slice of Mixed Berry pie=Rebanada de Pastel de Mezcla de Bayas +Basket with Mixed Berry pies=Cesta con Pasteles de Mezcla de Baya +Currently fruitless Bush=Arbusto actualmente infructuoso Basket=Cesta diff --git a/bushes_classic/locale/bushes_classic.fr.tr b/bushes_classic/locale/bushes_classic.fr.tr index 4400433..b64e3b6 100644 --- a/bushes_classic/locale/bushes_classic.fr.tr +++ b/bushes_classic/locale/bushes_classic.fr.tr @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Sugar=Sucre -Basket with Strawberry pies=Panier de tartes aux fraises -Cooked Strawberry pie=Tarte aux fraises (cuite) -Raw Strawberry pie=Tarte aux fraises (crue) -Slice of Strawberry pie=Part de tarte aux fraises Strawberry=Fraises +Raw Strawberry pie=Tarte aux fraises (crue) +Cooked Strawberry pie=Tarte aux fraises (cuite) +Slice of Strawberry pie=Part de tarte aux fraises +Basket with Strawberry pies=Panier de tartes aux fraises Strawberry Bush=Buisson de fraises -Basket with Blackberry pies=Panier de tartes aux fraises Blackberry=Mûres -Blackberry Bush=Buisson de mûres -Cooked Blackberry pie=Tarte aux mûres (cuite) Raw Blackberry pie=Tarte aux mûres (crue) +Cooked Blackberry pie=Tarte aux mûres (cuite) Slice of Blackberry pie=Part de tarte aux mûres -Basket with Blueberry pies=Panier de tartes aux mûres +Basket with Blackberry pies=Panier de tartes aux fraises +Blackberry Bush=Buisson de mûres Blueberry=Myrtilles -Blueberry Bush=Buisson de myrtilles -Cooked Blueberry pie=Tarte aux myrtilles (cuite) Raw Blueberry pie=Tarte aux myrtilles (crue) +Cooked Blueberry pie=Tarte aux myrtilles (cuite) Slice of Blueberry pie=Part de tarte aux myrtilles -Basket with Raspberry pies=Panier de tartes aux framboises -Cooked Raspberry pie=Tarte aux framboises (cuite) +Basket with Blueberry pies=Panier de tartes aux mûres +Blueberry Bush=Buisson de myrtilles Raspberry=Framboises -Raspberry Bush=Buisson de framboises Raw Raspberry pie=Tarte aux framboises (crue) +Cooked Raspberry pie=Tarte aux framboises (cuite) Slice of Raspberry pie=Part de tarts aux framboises -Basket with Gooseberry pies=Panier de tartes aux groseilles -Cooked Gooseberry pie=Tarte aux groseilles (cuite) +Basket with Raspberry pies=Panier de tartes aux framboises +Raspberry Bush=Buisson de framboises Gooseberry=Groseilles -Gooseberry Bush=Buisson de groseilles Raw Gooseberry pie=Tarte aux groseilles (crue) +Cooked Gooseberry pie=Tarte aux groseilles (cuite) Slice of Gooseberry pie=Part de tarte aux groseilles -Basket with Mixed Berry pies=Panier de tartes aux fruits rouges -Cooked Mixed Berry pie=Tarte aux fruits rouges (cuite) -Currently fruitless Bush=Buisson sans fruits pour l'instant +Basket with Gooseberry pies=Panier de tartes aux groseilles +Gooseberry Bush=Buisson de groseilles Mixed Berry=Fruits rouges Raw Mixed Berry pie=Tarte aux fruits rouges (crue) +Cooked Mixed Berry pie=Tarte aux fruits rouges (cuite) Slice of Mixed Berry pie=Part de tarte aux fruits rouges +Basket with Mixed Berry pies=Panier de tartes aux fruits rouges +Currently fruitless Bush=Buisson sans fruits pour l'instant Basket=Panier diff --git a/bushes_classic/locale/bushes_classic.tr.tr b/bushes_classic/locale/bushes_classic.tr.tr index 38ed28d..c88b716 100644 --- a/bushes_classic/locale/bushes_classic.tr.tr +++ b/bushes_classic/locale/bushes_classic.tr.tr @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# mahmutelmas06@hotmail.com, 2017. -# - Sugar=Şeker -Basket with Strawberry pies=Çilekli pasta sepeti -Cooked Strawberry pie=Pişmiş çilekli pasta -Raw Strawberry pie=Çilekli çiğ pasta -Slice of Strawberry pie=Çilekli pasta dilimi Strawberry=Çilek +Raw Strawberry pie=Çilekli çiğ pasta +Cooked Strawberry pie=Pişmiş çilekli pasta +Slice of Strawberry pie=Çilekli pasta dilimi +Basket with Strawberry pies=Çilekli pasta sepeti Strawberry Bush=Çilek fidanı -Basket with Blackberry pies=Böğürtlenli pasta sepeti Blackberry=Böğürtlen -Blackberry Bush=Böğürtlen fidanı -Cooked Blackberry pie=Pişmiş böğürtlenli pasta Raw Blackberry pie=Böğürtlenli çiğ pasta +Cooked Blackberry pie=Pişmiş böğürtlenli pasta Slice of Blackberry pie=Böğürtlenli pasta dilimi -Basket with Blueberry pies=Yaban mersini pastalı sepet +Basket with Blackberry pies=Böğürtlenli pasta sepeti +Blackberry Bush=Böğürtlen fidanı Blueberry=Yaban mersini -Blueberry Bush=Yaban mersini fidanı -Cooked Blueberry pie=Pişmiş yaban mersinli pasta Raw Blueberry pie=Yaban mersinli çiğ pasta +Cooked Blueberry pie=Pişmiş yaban mersinli pasta Slice of Blueberry pie=Yaban mersinli pasta dilimi -Basket with Raspberry pies=Ahududulu pasta sepeti -Cooked Raspberry pie=Pişmiş ahududulu pasta +Basket with Blueberry pies=Yaban mersini pastalı sepet +Blueberry Bush=Yaban mersini fidanı Raspberry=Ahududu -Raspberry Bush=Ahududu fidanı Raw Raspberry pie=Ahududulu çiğ pasta +Cooked Raspberry pie=Pişmiş ahududulu pasta Slice of Raspberry pie=Ahududulu pasta dilimi -Basket with Gooseberry pies=Bektaşi üzümlü pasta sepeti -Cooked Gooseberry pie=Pişmiş bektaşi üzümlü pasta +Basket with Raspberry pies=Ahududulu pasta sepeti +Raspberry Bush=Ahududu fidanı Gooseberry=Bektaşi üzümü -Gooseberry Bush=Bektaşi üzümü fidanı Raw Gooseberry pie=Bektaşi üzümlü çiğ pasta +Cooked Gooseberry pie=Pişmiş bektaşi üzümlü pasta Slice of Gooseberry pie=Bektaşi üzümlü pasta dilimi -Basket with Mixed Berry pies=Dutlu pasta sepeti -Cooked Mixed Berry pie=Pişmiş dutlu pasta -Currently fruitless Bush=Fidanı şu anda meyvesiz +Basket with Gooseberry pies=Bektaşi üzümlü pasta sepeti +Gooseberry Bush=Bektaşi üzümü fidanı Mixed Berry=Dut Raw Mixed Berry pie=Dutlu çiğ pasta +Cooked Mixed Berry pie=Pişmiş dutlu pasta Slice of Mixed Berry pie=Dutlu pasta dilimi +Basket with Mixed Berry pies=Dutlu pasta sepeti +Currently fruitless Bush=Fidanı şu anda meyvesiz Basket=Sepet diff --git a/bushes_classic/locale/template.txt b/bushes_classic/locale/template.txt index c721e23..69fc2a1 100644 --- a/bushes_classic/locale/template.txt +++ b/bushes_classic/locale/template.txt @@ -1,46 +1,39 @@ # textdomain: bushes_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Sugar= -Basket with Strawberry pies= -Cooked Strawberry pie= -Raw Strawberry pie= -Slice of Strawberry pie= Strawberry= +Raw Strawberry pie= +Cooked Strawberry pie= +Slice of Strawberry pie= +Basket with Strawberry pies= Strawberry Bush= -Basket with Blackberry pies= Blackberry= -Blackberry Bush= -Cooked Blackberry pie= Raw Blackberry pie= +Cooked Blackberry pie= Slice of Blackberry pie= -Basket with Blueberry pies= +Basket with Blackberry pies= +Blackberry Bush= Blueberry= -Blueberry Bush= -Cooked Blueberry pie= Raw Blueberry pie= +Cooked Blueberry pie= Slice of Blueberry pie= -Basket with Raspberry pies= -Cooked Raspberry pie= +Basket with Blueberry pies= +Blueberry Bush= Raspberry= -Raspberry Bush= Raw Raspberry pie= +Cooked Raspberry pie= Slice of Raspberry pie= -Basket with Gooseberry pies= -Cooked Gooseberry pie= +Basket with Raspberry pies= +Raspberry Bush= Gooseberry= -Gooseberry Bush= Raw Gooseberry pie= +Cooked Gooseberry pie= Slice of Gooseberry pie= -Basket with Mixed Berry pies= -Cooked Mixed Berry pie= -Currently fruitless Bush= +Basket with Gooseberry pies= +Gooseberry Bush= Mixed Berry= Raw Mixed Berry pie= +Cooked Mixed Berry pie= Slice of Mixed Berry pie= +Basket with Mixed Berry pies= +Currently fruitless Bush= Basket= diff --git a/bushes_classic/nodes.lua b/bushes_classic/nodes.lua index 835b9ca..1af4675 100644 --- a/bushes_classic/nodes.lua +++ b/bushes_classic/nodes.lua @@ -161,19 +161,13 @@ for i, bush_name in ipairs(bushes_classic.bushes) do groups = { dig_immediate = 3 }, }) - local texture_top, texture_bottom local groups = {snappy = 3, bush = 1, flammable = 2, attached_node=1} if bush_name == "mixed_berry" then bush_name = "fruitless"; - texture_top = "bushes_fruitless_bush_top.png" - texture_bottom = "bushes_fruitless_bush_bottom.png" groups.not_in_creative_inventory = 1 - else - texture_top = "bushes_bush_top.png" - texture_bottom = "bushes_bush_bottom.png" end - + local node_dig_prediction local node_placement_prediction if bush_name ~= "fruitless" then diff --git a/cavestuff/init.lua b/cavestuff/init.lua index 3f46ea9..d328f46 100644 --- a/cavestuff/init.lua +++ b/cavestuff/init.lua @@ -1,17 +1,2 @@ ------------------------------------------------------------------------------------------------ -local title = "Cave Stuff" -local version = "0.0.3" -local mname = "cavestuff" ------------------------------------------------------------------------------------------------ - --- support for i18n -local S = minetest.get_translator("cavestuff") - -cavestuff = {} - dofile(minetest.get_modpath("cavestuff").."/nodes.lua") dofile(minetest.get_modpath("cavestuff").."/mapgen.lua") - ------------------------------------------------------------------------------------------------ - -print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...") diff --git a/cavestuff/locale/cavestuff.de.tr b/cavestuff/locale/cavestuff.de.tr index 43f68fb..69bb0cc 100644 --- a/cavestuff/locale/cavestuff.de.tr +++ b/cavestuff/locale/cavestuff.de.tr @@ -1,11 +1,4 @@ # textdomain: cavestuff - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Pebble=Kieselstein Desert Pebble=Wüstenkiesel Stalactite=Stalaktit diff --git a/cavestuff/locale/cavestuff.eo.tr b/cavestuff/locale/cavestuff.eo.tr index c077ae8..9da0f26 100644 --- a/cavestuff/locale/cavestuff.eo.tr +++ b/cavestuff/locale/cavestuff.eo.tr @@ -1,11 +1,4 @@ # textdomain: cavestuff - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Pebble=Ŝtoneto Desert Pebble=Dezerta Ŝtoneto Stalactite=Stalaktito diff --git a/cavestuff/locale/cavestuff.fr.tr b/cavestuff/locale/cavestuff.fr.tr index aae88ac..0c48fb0 100644 --- a/cavestuff/locale/cavestuff.fr.tr +++ b/cavestuff/locale/cavestuff.fr.tr @@ -1,11 +1,4 @@ # textdomain: cavestuff - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Pebble=Caillou Desert Pebble=Caillou du désert Stalactite=Stalactite diff --git a/cavestuff/locale/template.txt b/cavestuff/locale/template.txt index 8e8d18a..aae2112 100644 --- a/cavestuff/locale/template.txt +++ b/cavestuff/locale/template.txt @@ -1,11 +1,4 @@ # textdomain: cavestuff - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Pebble= Desert Pebble= Stalactite= diff --git a/cavestuff/nodes.lua b/cavestuff/nodes.lua index 7dcf6b7..a5211d7 100644 --- a/cavestuff/nodes.lua +++ b/cavestuff/nodes.lua @@ -12,33 +12,32 @@ minetest.register_node("cavestuff:pebble_1",{ description = S("Pebble"), drawtype = "mesh", mesh = "cavestuff_pebble.obj", - tiles = {"undergrowth_pebble.png"}, - paramtype = "light", + tiles = {"undergrowth_pebble.png"}, + paramtype = "light", paramtype2 = "facedir", - groups = {cracky=3, stone=1, attached_node=1}, - selection_box = cbox, - collision_box = cbox, - on_place = function(itemstack, placer, pointed_thing) + groups = {cracky=3, stone=1, attached_node=1}, + selection_box = cbox, + collision_box = cbox, + on_place = function(itemstack, placer, pointed_thing) -- place a random pebble node local stack = ItemStack("cavestuff:pebble_"..math.random(1,2)) local ret = minetest.item_place(stack, placer, pointed_thing) return ItemStack("cavestuff:pebble_1 "..itemstack:get_count()-(1-ret:get_count())) end, - sounds = default.node_sound_stone_defaults(), + sounds = default.node_sound_stone_defaults(), }) minetest.register_node("cavestuff:pebble_2",{ drawtype = "mesh", mesh = "cavestuff_pebble.obj", - tiles = {"undergrowth_pebble.png"}, + tiles = {"undergrowth_pebble.png"}, drop = "cavestuff:pebble_1", - tiles = {"undergrowth_pebble.png"}, - paramtype = "light", + paramtype = "light", paramtype2 = "facedir", - groups = {cracky=3, stone=1, attached_node=1, not_in_creative_inventory=1}, + groups = {cracky=3, stone=1, attached_node=1, not_in_creative_inventory=1}, selection_box = cbox, collision_box = cbox, - sounds = default.node_sound_stone_defaults(), + sounds = default.node_sound_stone_defaults(), }) minetest.register_node("cavestuff:desert_pebble_1",{ @@ -100,7 +99,7 @@ minetest.register_node("cavestuff:stalactite_1",{ if not placer then return end local playername = placer:get_player_name() if minetest.is_protected(place, playername) - or minetest.is_protected(above, playername) then + or minetest.is_protected(above, playername) then minetest.record_protection_violation(place, playername) return end @@ -156,5 +155,3 @@ minetest.register_node("cavestuff:stalactite_3",{ } }, }) - ---Stalagmites diff --git a/dryplants/crafting.lua b/dryplants/crafting.lua index 349661c..97be53e 100644 --- a/dryplants/crafting.lua +++ b/dryplants/crafting.lua @@ -53,7 +53,7 @@ minetest.register_craft({ {"default:stick",""} } }) -if minetest.get_modpath("flint") ~= nil then +if minetest.get_modpath("flint") then minetest.register_craft({ output = "dryplants:sickle", recipe = { @@ -63,7 +63,7 @@ if minetest.get_modpath("flint") ~= nil then } }) end -if minetest.get_modpath("stoneage") ~= nil then +if minetest.get_modpath("stoneage") then minetest.register_craft({ output = "dryplants:sickle", recipe = { diff --git a/dryplants/init.lua b/dryplants/init.lua index 77ca2dd..a3256b9 100644 --- a/dryplants/init.lua +++ b/dryplants/init.lua @@ -1,8 +1,3 @@ ------------------------------------------------------------------------------------------------ -local title = "Grasses" -- former "Dry plants" -local version = "0.1.5" -local mname = "dryplants" ------------------------------------------------------------------------------------------------ -- by Mossmanikin -- textures & ideas partly by Neuromancer @@ -20,13 +15,13 @@ dofile(minetest.get_modpath("dryplants").."/crafting.lua") dofile(minetest.get_modpath("dryplants").."/settings.txt") dofile(minetest.get_modpath("dryplants").."/reed.lua") if REEDMACE_GENERATES == true then -dofile(minetest.get_modpath("dryplants").."/reedmace.lua") + dofile(minetest.get_modpath("dryplants").."/reedmace.lua") end if SMALL_JUNCUS_GENERATES == true then -dofile(minetest.get_modpath("dryplants").."/juncus.lua") + dofile(minetest.get_modpath("dryplants").."/juncus.lua") end if EXTRA_TALL_GRASS_GENERATES == true then -dofile(minetest.get_modpath("dryplants").."/moregrass.lua") + dofile(minetest.get_modpath("dryplants").."/moregrass.lua") end --dofile(minetest.get_modpath("dryplants").."/meadowvariation.lua") @@ -201,7 +196,3 @@ minetest.register_abm({ end end, }) - ------------------------------------------------------------------------------------------------ -print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...") ------------------------------------------------------------------------------------------------ diff --git a/dryplants/juncus.lua b/dryplants/juncus.lua index 0bfd635..186b4b0 100644 --- a/dryplants/juncus.lua +++ b/dryplants/juncus.lua @@ -46,6 +46,10 @@ minetest.register_node("dryplants:juncus", { fixed = {-7/16, -1/2, -7/16, 7/16, 0, 7/16}, }, on_place = function(itemstack, placer, pointed_thing) + if not itemstack or not placer or not pointed_thing then + return + end + local playername = placer:get_player_name() if minetest.is_protected(pointed_thing.above, playername) or minetest.is_protected(pointed_thing.under, playername) then diff --git a/dryplants/locale/dryplants.de.tr b/dryplants/locale/dryplants.de.tr index 442cd79..8f5dff9 100644 --- a/dryplants/locale/dryplants.de.tr +++ b/dryplants/locale/dryplants.de.tr @@ -1,11 +1,4 @@ # textdomain: dryplants - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Sickle=Sichel Cut Grass=Gras schneiden Hay=Heu diff --git a/dryplants/locale/dryplants.eo.tr b/dryplants/locale/dryplants.eo.tr index 1ae0121..a9b36b9 100644 --- a/dryplants/locale/dryplants.eo.tr +++ b/dryplants/locale/dryplants.eo.tr @@ -1,11 +1,4 @@ # textdomain: dryplants - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Sickle= Cut Grass=Tranĉita Herbenon Hay=Fojno diff --git a/dryplants/locale/dryplants.fr.tr b/dryplants/locale/dryplants.fr.tr index 4172ea8..4345799 100644 --- a/dryplants/locale/dryplants.fr.tr +++ b/dryplants/locale/dryplants.fr.tr @@ -1,11 +1,4 @@ # textdomain: dryplants - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Sickle=Faucille Cut Grass=Herbe coupée Hay=Foin diff --git a/dryplants/locale/template.txt b/dryplants/locale/template.txt index a95fb53..a244774 100644 --- a/dryplants/locale/template.txt +++ b/dryplants/locale/template.txt @@ -1,11 +1,4 @@ # textdomain: dryplants - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Sickle= Cut Grass= Hay= diff --git a/ferns/crafting.lua b/ferns/crafting.lua index f32aa69..db419ef 100644 --- a/ferns/crafting.lua +++ b/ferns/crafting.lua @@ -30,7 +30,7 @@ minetest.register_craft({ ----------------------------------------------------------------------------------------------- -- FIDDLEHEAD ----------------------------------------------------------------------------------------------- -minetest.register_alias("archaeplantae:fiddlehead", "ferns:fiddlehead") +minetest.register_alias("archaeplantae:fiddlehead", "ferns:fiddlehead") minetest.register_craftitem("ferns:fiddlehead", { description = S("Fiddlehead"), @@ -51,7 +51,7 @@ minetest.register_craftitem("ferns:fiddlehead_roasted", { ----------------------------------------------------------------------------------------------- -- FERN TUBER ----------------------------------------------------------------------------------------------- -minetest.register_alias("archaeplantae:ferntuber", "ferns:ferntuber") +minetest.register_alias("archaeplantae:ferntuber", "ferns:ferntuber") minetest.register_craftitem("ferns:ferntuber", { description = S("Fern Tuber"), @@ -64,7 +64,7 @@ minetest.register_craft({ cooktime = 3, }) -minetest.register_alias("archaeplantae:ferntuber_roasted", "ferns:ferntuber_roasted") +minetest.register_alias("archaeplantae:ferntuber_roasted", "ferns:ferntuber_roasted") minetest.register_craftitem("ferns:ferntuber_roasted", { description = S("Roasted Fern Tuber"), diff --git a/ferns/gianttreefern.lua b/ferns/gianttreefern.lua index 58c8f79..bc1a334 100644 --- a/ferns/gianttreefern.lua +++ b/ferns/gianttreefern.lua @@ -84,8 +84,8 @@ abstract_ferns.grow_giant_tree_fern = function(pos) local brk = false for i = 1, size-3 do pos_aux.y = pos.y + i - local name = minetest.get_node(pos_aux).name - if not (name == "air" or (i == 1 and name == "ferns:sapling_giant_tree_fern")) then + local nodename = minetest.get_node(pos_aux).name + if not (nodename == "air" or (i == 1 and nodename == "ferns:sapling_giant_tree_fern")) then brk = true break end diff --git a/ferns/init.lua b/ferns/init.lua index 03ce8a9..14249b3 100644 --- a/ferns/init.lua +++ b/ferns/init.lua @@ -1,16 +1,5 @@ ------------------------------------------------------------------------------------------------ -local title = "Ferns" -- former "Archae Plantae" -local version = "0.2.1" -local mname = "ferns" -- former "archaeplantae" ------------------------------------------------------------------------------------------------ --- (by Mossmanikin) ------------------------------------------------------------------------------------------------ - abstract_ferns = {} --- support for i18n -local S = minetest.get_translator("ferns") - dofile(minetest.get_modpath("ferns").."/settings.lua") if abstract_ferns.config.enable_lady_fern == true then @@ -30,42 +19,3 @@ if abstract_ferns.config.enable_giant_treefern == true then end dofile(minetest.get_modpath("ferns").."/crafting.lua") - - ------------------------------------------------------------------------------ --- TESTS ------------------------------------------------------------------------------ -local run_tests = true -- set to false to skip - -if run_tests then - - -- These are, essentially, unit tests to make sure that all required item - -- strings are registered. The init sequence is not time critical so leaving - -- them here won't affect performance. - - -- Check node names - if abstract_ferns.config.enable_horsetails then - print("[Mod] " ..title.. " Checking horsetail item strings") - assert(minetest.registered_items["ferns:horsetail_01"] ~= nil) - assert(minetest.registered_items["ferns:horsetail_02"] ~= nil) - assert(minetest.registered_items["ferns:horsetail_03"] ~= nil) - assert(minetest.registered_items["ferns:horsetail_04"] ~= nil) - end - if abstract_ferns.config.enable_lady_fern then - print("[Mod] ".. title .." Checking lady fern item strings") - assert(minetest.registered_items["ferns:fern_01"] ~= nil) - assert(minetest.registered_items["ferns:fern_02"] ~= nil) - assert(minetest.registered_items["ferns:fern_03"] ~= nil) - end - if abstract_ferns.config.enable_treefern then - print("[Mod] ".. title .." Checking tree fern item strings") - assert(minetest.registered_items["ferns:tree_fern_leaves"] ~= nil) - assert(minetest.registered_items["ferns:tree_fern_leaves_02"] ~= nil) - assert(minetest.registered_items["ferns:fern_trunk"] ~= nil) - assert(minetest.registered_items["ferns:sapling_tree_fern"] ~= nil) - end -end - ------------------------------------------------------------------------------------------------ -print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...") ------------------------------------------------------------------------------------------------ diff --git a/ferns/locale/ferns.de.tr b/ferns/locale/ferns.de.tr index 73e784d..a9582d7 100644 --- a/ferns/locale/ferns.de.tr +++ b/ferns/locale/ferns.de.tr @@ -1,18 +1,9 @@ # textdomain: ferns - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - - Fiddlehead=Geigenkopf Roasted Fiddlehead=Gerösteter Geigenkopf Fern Tuber=Farnknolle Roasted Fern Tuber=Geröstete Farnknolle Lady-fern (Athyrium)=Frauenfarn (Athyrium) -Tree Fern Crown (Dicksonia)=Baumfarnkrone (Dicksonia) Giant Tree Fern Leaves=Riesige Baumfarnblätter Giant Tree Fern Leave End=Riesiges Baumfarnblattende Giant Fern Trunk=Riesiger Baumfarnstamm @@ -21,3 +12,4 @@ Young Horsetail (Equisetum)=Junger Schachtelhalm (Equisetum) Horsetail (Equisetum)=Schachtelhalm (Equisetum) Fern Trunk (Dicksonia)=Farnstamm (Dicksonia) Tree Fern Sapling (Dicksonia)=Baumfarnsetzling (Dicksonia) +Tree Fern Crown (Dicksonia)=Baumfarnkrone (Dicksonia) diff --git a/ferns/locale/ferns.eo.tr b/ferns/locale/ferns.eo.tr index 0dc3da3..ad0bde3 100644 --- a/ferns/locale/ferns.eo.tr +++ b/ferns/locale/ferns.eo.tr @@ -1,18 +1,9 @@ # textdomain: ferns - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - - Fiddlehead=Filika Supro Roasted Fiddlehead=Rostita Filika Supro Fern Tuber=Filika Tubero Roasted Fern Tuber=Rostita Filika Tubero Lady-fern (Athyrium)=Afiriumo (Athyrium) -Tree Fern Crown (Dicksonia)=Krono de Arba Filiko Giant Tree Fern Leaves=Folioj de Giganta Arba Filiko Giant Tree Fern Leave End=Folifino de Giganta Arba Filiko Giant Fern Trunk=Trunko de Giganta Arba Filiko @@ -21,3 +12,4 @@ Young Horsetail (Equisetum)=Juna Ekvizeto (Equisetum) Horsetail (Equisetum)=Ekvizeto (Equisetum) Fern Trunk (Dicksonia)=Trunko de Arba Filiko (Dicksonia) Tree Fern Sapling (Dicksonia)=Arbido de Arba Filiko (Dicksonia) +Tree Fern Crown (Dicksonia)=Krono de Arba Filiko diff --git a/ferns/locale/ferns.fr.tr b/ferns/locale/ferns.fr.tr index 9eb8d74..c893605 100644 --- a/ferns/locale/ferns.fr.tr +++ b/ferns/locale/ferns.fr.tr @@ -1,17 +1,9 @@ # textdomain: ferns - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Fiddlehead=Crosse de fougère Roasted Fiddlehead=Crosse de fougère rôtie Fern Tuber=Tubercule de fougère Roasted Fern Tuber=Tubercule de fougère rôti Lady-fern (Athyrium)=Fougère (Athyrium) -Tree Fern Crown (Dicksonia)=Fougère en couronne (Dicksonia) Giant Tree Fern Leaves=Feuilles de fougère géante Giant Tree Fern Leave End=Feuilles de fougère géante (extrémité) Giant Fern Trunk=Tronc de fougère géante @@ -20,3 +12,4 @@ Young Horsetail (Equisetum)=Pousse de prêle (Equisetum) Horsetail (Equisetum)=Prêle (Equisetum) Fern Trunk (Dicksonia)=Tronc de fougère en couronne (Dicksonia) Tree Fern Sapling (Dicksonia)=Pousse de fougère en couronne (Dicksonia) +Tree Fern Crown (Dicksonia)=Fougère en couronne (Dicksonia) diff --git a/ferns/locale/template.txt b/ferns/locale/template.txt index a824e9c..b438c8c 100644 --- a/ferns/locale/template.txt +++ b/ferns/locale/template.txt @@ -1,18 +1,9 @@ # textdomain: ferns - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - - Fiddlehead= Roasted Fiddlehead= Fern Tuber= Roasted Fern Tuber= Lady-fern (Athyrium)= -Tree Fern Crown (Dicksonia)= Giant Tree Fern Leaves= Giant Tree Fern Leave End= Giant Fern Trunk= @@ -21,3 +12,4 @@ Young Horsetail (Equisetum)= Horsetail (Equisetum)= Fern Trunk (Dicksonia)= Tree Fern Sapling (Dicksonia)= +Tree Fern Crown (Dicksonia)= diff --git a/molehills/init.lua b/molehills/init.lua index c682318..c6f7824 100644 --- a/molehills/init.lua +++ b/molehills/init.lua @@ -1,13 +1,10 @@ ------------------------------------------------------------------------------------------------ -- Idea by Sokomine -- Code & textures by Mossmanikin -- support for i18n local S = minetest.get_translator("molehills") ------------------------------------------------------------------------------------------------ --- NoDe ------------------------------------------------------------------------------------------------ +-- Node local mh_cbox = { type = "fixed", fixed = { -0.5, -0.5, -0.5, 0.5, -0.125, 0.5} @@ -27,9 +24,7 @@ minetest.register_node("molehills:molehill",{ sounds = default.node_sound_dirt_defaults(), }) ------------------------------------------------------------------------------------------------ --- CRaFTiNG ------------------------------------------------------------------------------------------------ +-- Crafting minetest.register_craft({ -- molehills --> dirt output = "default:dirt", recipe = { @@ -38,9 +33,7 @@ minetest.register_craft({ -- molehills --> dirt } }) ------------------------------------------------------------------------------------------------ --- GeNeRaTiNG ------------------------------------------------------------------------------------------------ +-- Generating minetest.register_decoration({ decoration = { "molehills:molehill" diff --git a/molehills/locale/molehills.de.tr b/molehills/locale/molehills.de.tr index ba98372..07d8f7c 100644 --- a/molehills/locale/molehills.de.tr +++ b/molehills/locale/molehills.de.tr @@ -1,9 +1,2 @@ # textdomain: molehills - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Mole Hill=Maulwurfshügel diff --git a/molehills/locale/molehills.eo.tr b/molehills/locale/molehills.eo.tr index 3740d78..ca7a1c6 100644 --- a/molehills/locale/molehills.eo.tr +++ b/molehills/locale/molehills.eo.tr @@ -1,9 +1,2 @@ # textdomain: molehills - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Mole Hill=Talpa Monteto diff --git a/molehills/locale/molehills.fr.tr b/molehills/locale/molehills.fr.tr index f3f9aab..b0eaf66 100644 --- a/molehills/locale/molehills.fr.tr +++ b/molehills/locale/molehills.fr.tr @@ -1,9 +1,2 @@ # textdomain: molehills - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Mole Hill=Taupinière diff --git a/molehills/locale/template.txt b/molehills/locale/template.txt index 46fc119..bd7f836 100644 --- a/molehills/locale/template.txt +++ b/molehills/locale/template.txt @@ -1,9 +1,2 @@ # textdomain: molehills - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Mole Hill= diff --git a/nature_classic/global_function.lua b/nature_classic/global_function.lua index b83201c..ebf5529 100644 --- a/nature_classic/global_function.lua +++ b/nature_classic/global_function.lua @@ -2,7 +2,7 @@ local function process_blossom_queue_item() local pos = nature.blossomqueue[1][1] - local node = nature.blossomqueue[1][2] + -- local node = nature.blossomqueue[1][2] local replace = nature.blossomqueue[1][3] if (nature.blossomqueue[1][3] == nature.blossom_node and not nature:is_near_water(pos)) then table.remove(nature.blossomqueue, 1) -- don't grow if it's not near water, pop from queue. @@ -32,7 +32,7 @@ end) function nature.enqueue_node(pos, node, replace) local idx = #nature.blossomqueue if idx < nature.blossomqueue_max then - local enqueue_prob = 0 + local enqueue_prob if idx < nature.blossomqueue_max * 0.8 then enqueue_prob = 1 else diff --git a/nature_classic/init.lua b/nature_classic/init.lua index 48a207e..0d0de99 100644 --- a/nature_classic/init.lua +++ b/nature_classic/init.lua @@ -6,8 +6,6 @@ local current_mod_name = minetest.get_current_modname() nature = {} --- support for i18n -local S = minetest.get_translator("nature_classic") nature.blossomqueue = {} nature.blossomqueue_max = 1000 @@ -25,7 +23,7 @@ if minetest.get_modpath("moretrees") then nature.blossom_node = "moretrees:apple_blossoms" nature.blossom_leaves = "moretrees:apple_tree_leaves" nature.blossom_textures = { "moretrees_apple_tree_leaves.png^nature_blossom.png" } - nature.blossom_groups = { snappy = 3, leafdecay = 1, leaves = 1, flammable = 2, moretrees_leaves = 1 }, + nature.blossom_groups = { snappy = 3, leafdecay = 1, leaves = 1, flammable = 2, moretrees_leaves = 1 } minetest.register_alias("nature:blossom", "default:leaves") end @@ -39,12 +37,6 @@ nature.apple_spread = 2 nature.meta_blossom_time = "blossom_time" nature.blossom_duration = nature.blossom_delay -function dumppos(pos) - return "("..pos.x..","..pos.y..","..pos.z..")" -end - dofile(minetest.get_modpath(current_mod_name) .. "/config.lua") dofile(minetest.get_modpath(current_mod_name) .. "/global_function.lua") dofile(minetest.get_modpath(current_mod_name) .. "/blossom.lua") - -minetest.log("info", S("[Nature Classic] loaded!")) diff --git a/nature_classic/locale/nature_classic.de.tr b/nature_classic/locale/nature_classic.de.tr index 9902d27..1f1f4d0 100644 --- a/nature_classic/locale/nature_classic.de.tr +++ b/nature_classic/locale/nature_classic.de.tr @@ -1,10 +1,2 @@ # textdomain: nature_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Apple blossoms=Apfelblüten -[Nature Classic] loaded!=[Nature Classic] geladen! diff --git a/nature_classic/locale/nature_classic.fr.tr b/nature_classic/locale/nature_classic.fr.tr index ffa9c50..6c60509 100644 --- a/nature_classic/locale/nature_classic.fr.tr +++ b/nature_classic/locale/nature_classic.fr.tr @@ -1,10 +1,2 @@ # textdomain: nature_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Apple blossoms=Fleurs de pommier -[Nature Classic] loaded!=[Nature Classic] chargé.! diff --git a/nature_classic/locale/template.txt b/nature_classic/locale/template.txt index c39a57b..a2c7ee4 100644 --- a/nature_classic/locale/template.txt +++ b/nature_classic/locale/template.txt @@ -1,10 +1,2 @@ # textdomain: nature_classic - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Apple blossoms= -[Nature Classic] loaded!= diff --git a/pl_seaweed/init.lua b/pl_seaweed/init.lua index 49885d4..e842478 100644 --- a/pl_seaweed/init.lua +++ b/pl_seaweed/init.lua @@ -47,7 +47,11 @@ for i in ipairs(algae_list) do liquids_pointable = true, drop = "flowers:seaweed", on_place = function(itemstack, placer, pointed_thing) - local keys=placer:get_player_control() + if not itemstack or not placer or not pointed_thing then + return + end + + local keys = placer:get_player_control() local pt = pointed_thing local place_pos = nil @@ -161,9 +165,9 @@ biome_lib.register_on_generate({ pl_seaweed.grow_seaweed ) -minetest.register_alias( "flowers:flower_seaweed" , "flowers:seaweed" ) -minetest.register_alias( "along_shore:pondscum_1" , "flowers:seaweed" ) -minetest.register_alias( "along_shore:seaweed_1" , "flowers:seaweed" ) -minetest.register_alias( "along_shore:seaweed_2" , "flowers:seaweed_2" ) -minetest.register_alias( "along_shore:seaweed_3" , "flowers:seaweed_3" ) -minetest.register_alias( "along_shore:seaweed_4" , "flowers:seaweed_4" ) +minetest.register_alias("flowers:flower_seaweed", "flowers:seaweed") +minetest.register_alias("along_shore:pondscum_1", "flowers:seaweed") +minetest.register_alias("along_shore:seaweed_1", "flowers:seaweed") +minetest.register_alias("along_shore:seaweed_2", "flowers:seaweed_2") +minetest.register_alias("along_shore:seaweed_3", "flowers:seaweed_3") +minetest.register_alias("along_shore:seaweed_4", "flowers:seaweed_4") diff --git a/pl_seaweed/locale/pl_seaweed.de.tr b/pl_seaweed/locale/pl_seaweed.de.tr index 89ed60d..6c34f92 100644 --- a/pl_seaweed/locale/pl_seaweed.de.tr +++ b/pl_seaweed/locale/pl_seaweed.de.tr @@ -1,11 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Xanthin, 2017. -# - - - Seaweed=Seetang diff --git a/pl_seaweed/locale/pl_seaweed.fr.tr b/pl_seaweed/locale/pl_seaweed.fr.tr index 5a76eb8..39dbbcf 100644 --- a/pl_seaweed/locale/pl_seaweed.fr.tr +++ b/pl_seaweed/locale/pl_seaweed.fr.tr @@ -1,10 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - - Seaweed=Algues diff --git a/pl_seaweed/locale/pl_seaweed.tr.tr b/pl_seaweed/locale/pl_seaweed.tr.tr index c1aa4bd..0e11bb1 100644 --- a/pl_seaweed/locale/pl_seaweed.tr.tr +++ b/pl_seaweed/locale/pl_seaweed.tr.tr @@ -1,10 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# mahmutelmas06@hotmail.com, 2017. -# - - Seaweed=Deniz yosunu diff --git a/pl_seaweed/locale/pl_seawood.eo.tr b/pl_seaweed/locale/pl_seawood.eo.tr index 40b89cb..f76dfe2 100644 --- a/pl_seaweed/locale/pl_seawood.eo.tr +++ b/pl_seaweed/locale/pl_seawood.eo.tr @@ -1,11 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - - - Seaweed=Algo diff --git a/pl_seaweed/locale/pl_seawood.es.tr b/pl_seaweed/locale/pl_seawood.es.tr index 2927e3c..bcd13a2 100644 --- a/pl_seaweed/locale/pl_seawood.es.tr +++ b/pl_seaweed/locale/pl_seawood.es.tr @@ -1,10 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Carlos Barraza , 2017. -# - - Seaweed=Algas marinas diff --git a/pl_seaweed/locale/template.txt b/pl_seaweed/locale/template.txt index 1950d90..e2f00f6 100644 --- a/pl_seaweed/locale/template.txt +++ b/pl_seaweed/locale/template.txt @@ -1,11 +1,2 @@ # textdomain: pl_seaweed - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - - - Seaweed= diff --git a/pl_sunflowers/locale/pl_sunflowers.de.tr b/pl_sunflowers/locale/pl_sunflowers.de.tr index ab40a42..d82b0c7 100644 --- a/pl_sunflowers/locale/pl_sunflowers.de.tr +++ b/pl_sunflowers/locale/pl_sunflowers.de.tr @@ -1,11 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Xanthin, 2017. -# - - - Sunflower=Sonnenblume diff --git a/pl_sunflowers/locale/pl_sunflowers.eo.tr b/pl_sunflowers/locale/pl_sunflowers.eo.tr index 8042897..f9203e0 100644 --- a/pl_sunflowers/locale/pl_sunflowers.eo.tr +++ b/pl_sunflowers/locale/pl_sunflowers.eo.tr @@ -1,11 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - - - Sunflower=Sunfloro diff --git a/pl_sunflowers/locale/pl_sunflowers.es.tr b/pl_sunflowers/locale/pl_sunflowers.es.tr index b57f3b6..2d5edc3 100644 --- a/pl_sunflowers/locale/pl_sunflowers.es.tr +++ b/pl_sunflowers/locale/pl_sunflowers.es.tr @@ -1,10 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Carlos Barraza , 2017. -# - - Sunflower=Girasol diff --git a/pl_sunflowers/locale/pl_sunflowers.fr.tr b/pl_sunflowers/locale/pl_sunflowers.fr.tr index 1c04e4f..aea069f 100644 --- a/pl_sunflowers/locale/pl_sunflowers.fr.tr +++ b/pl_sunflowers/locale/pl_sunflowers.fr.tr @@ -1,10 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - - Sunflower=Tournesol diff --git a/pl_sunflowers/locale/pl_sunflowers.tr.tr b/pl_sunflowers/locale/pl_sunflowers.tr.tr index 5b6409f..13e5a85 100644 --- a/pl_sunflowers/locale/pl_sunflowers.tr.tr +++ b/pl_sunflowers/locale/pl_sunflowers.tr.tr @@ -1,10 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# mahmutelmas06@hotmail.com, 2017. -# - - Sunflower=Ayçiçeği diff --git a/pl_sunflowers/locale/template.txt b/pl_sunflowers/locale/template.txt index 46c6f0a..96186a8 100644 --- a/pl_sunflowers/locale/template.txt +++ b/pl_sunflowers/locale/template.txt @@ -1,11 +1,2 @@ # textdomain: pl_sunflowers - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - - - Sunflower= diff --git a/pl_waterlilies/init.lua b/pl_waterlilies/init.lua index 57edad3..1a33cbb 100644 --- a/pl_waterlilies/init.lua +++ b/pl_waterlilies/init.lua @@ -59,7 +59,11 @@ for i in ipairs(lilies_list) do liquids_pointable = true, drop = "flowers:waterlily", on_place = function(itemstack, placer, pointed_thing) - local keys=placer:get_player_control() + if not itemstack or not placer or not pointed_thing then + return + end + + local keys = placer:get_player_control() local pt = pointed_thing local place_pos = nil @@ -86,7 +90,6 @@ for i in ipairs(lilies_list) do local nodename = "default:cobble" -- if this block appears, something went....wrong :-) if not keys["sneak"] then - local node = minetest.get_node(pt.under) local waterlily = math.random(1,8) if waterlily == 1 then nodename = "flowers:waterlily" @@ -158,8 +161,8 @@ minetest.register_alias( "flowers:flower_waterlily", "flowers:waterlily") minetest.register_alias( "flowers:flower_waterlily_225", "flowers:waterlily_225") minetest.register_alias( "flowers:flower_waterlily_45", "flowers:waterlily_45") minetest.register_alias( "flowers:flower_waterlily_675", "flowers:waterlily_675") -minetest.register_alias( "trunks:lilypad" , "flowers:waterlily_s1" ) -minetest.register_alias( "along_shore:lilypads_1" , "flowers:waterlily_s1" ) -minetest.register_alias( "along_shore:lilypads_2" , "flowers:waterlily_s2" ) -minetest.register_alias( "along_shore:lilypads_3" , "flowers:waterlily_s3" ) -minetest.register_alias( "along_shore:lilypads_4" , "flowers:waterlily_s4" ) +minetest.register_alias( "trunks:lilypad", "flowers:waterlily_s1") +minetest.register_alias( "along_shore:lilypads_1", "flowers:waterlily_s1") +minetest.register_alias( "along_shore:lilypads_2", "flowers:waterlily_s2") +minetest.register_alias( "along_shore:lilypads_3", "flowers:waterlily_s3") +minetest.register_alias( "along_shore:lilypads_4", "flowers:waterlily_s4") diff --git a/pl_waterlilies/locale/pl_waterlilies.de.tr b/pl_waterlilies/locale/pl_waterlilies.de.tr index 58de1f5..09558c5 100644 --- a/pl_waterlilies/locale/pl_waterlilies.de.tr +++ b/pl_waterlilies/locale/pl_waterlilies.de.tr @@ -1,11 +1,2 @@ # textdomain: pl_waterlilies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Xanthin, 2017. -# - - - Waterlily=Seerose diff --git a/pl_waterlilies/locale/pl_waterlilies.eo.tr b/pl_waterlilies/locale/pl_waterlilies.eo.tr index 0c188eb..c2de467 100644 --- a/pl_waterlilies/locale/pl_waterlilies.eo.tr +++ b/pl_waterlilies/locale/pl_waterlilies.eo.tr @@ -1,11 +1,2 @@ -# textdomain: pl_waterlillies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - - - +# textdomain: pl_waterlilies Waterlily=Akvolilio diff --git a/pl_waterlilies/locale/pl_waterlilies.es.tr b/pl_waterlilies/locale/pl_waterlilies.es.tr index bf93642..55f8874 100644 --- a/pl_waterlilies/locale/pl_waterlilies.es.tr +++ b/pl_waterlilies/locale/pl_waterlilies.es.tr @@ -1,10 +1,2 @@ # textdomain: pl_waterlilies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Carlos Barraza , 2017. -# - - Waterlily=Lirio de agua diff --git a/pl_waterlilies/locale/pl_waterlilies.fr.tr b/pl_waterlilies/locale/pl_waterlilies.fr.tr index c0e0fd1..0770369 100644 --- a/pl_waterlilies/locale/pl_waterlilies.fr.tr +++ b/pl_waterlilies/locale/pl_waterlilies.fr.tr @@ -1,10 +1,2 @@ # textdomain: pl_waterlilies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - - Waterlily=Nénuphar diff --git a/pl_waterlilies/locale/pl_waterlilies.tr.tr b/pl_waterlilies/locale/pl_waterlilies.tr.tr index ae05de6..b9f30e4 100644 --- a/pl_waterlilies/locale/pl_waterlilies.tr.tr +++ b/pl_waterlilies/locale/pl_waterlilies.tr.tr @@ -1,10 +1,2 @@ # textdomain: pl_waterlilies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# mahmutelmas06@hotmail.com, 2017. -# - - Waterlily=Nilüfer diff --git a/pl_waterlilies/locale/template.txt b/pl_waterlilies/locale/template.txt index bdf61b3..f9399c7 100644 --- a/pl_waterlilies/locale/template.txt +++ b/pl_waterlilies/locale/template.txt @@ -1,11 +1,2 @@ -# textdomain: pl_waterlillies - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - - - +# textdomain: pl_waterlilies Waterlily= diff --git a/poisonivy/init.lua b/poisonivy/init.lua index 0c914fa..f0e9d9d 100644 --- a/poisonivy/init.lua +++ b/poisonivy/init.lua @@ -1,5 +1,4 @@ -- This file supplies poison ivy for the plantlife modpack --- Last revision: 2013-01-24 -- support for i18n local S = minetest.get_translator("poisonivy") @@ -20,7 +19,7 @@ local walls_list = { "default:jungletree", "default:stone_with_coal", "default:stone_with_iron" -}, +} minetest.register_node('poisonivy:seedling', { description = S("Poison ivy (seedling)"), drawtype = 'plantlike', @@ -100,5 +99,3 @@ biome_lib.update_plant({ verticals_list = walls_list, ground_nodes = {"default:dirt_with_grass"} }) - -print("[Poison Ivy] Loaded.") diff --git a/poisonivy/locale/poisonivy.de.tr b/poisonivy/locale/poisonivy.de.tr index 85b9f13..4b337a2 100644 --- a/poisonivy/locale/poisonivy.de.tr +++ b/poisonivy/locale/poisonivy.de.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Xanthin, 2017. -# - Poison ivy (seedling)=Giftefeu (Saemling) Poison ivy (sproutling)=Giftefeu (Sproessling) Poison ivy (climbing plant)=Giftefeu (Kletterpflanze) -[Poison Ivy] Loaded.=[Poison Ivy] Geladen. diff --git a/poisonivy/locale/poisonivy.eo.tr b/poisonivy/locale/poisonivy.eo.tr index d0cb098..8db7877 100644 --- a/poisonivy/locale/poisonivy.eo.tr +++ b/poisonivy/locale/poisonivy.eo.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Poison ivy (seedling)=Venena hedero (plantido) Poison ivy (sproutling)=Venena hedero (ĝermanta) Poison ivy (climbing plant)=Venena hedero (grimpplanto) -[Poison Ivy] Loaded.=[Poison Ivy] ŝarĝita. diff --git a/poisonivy/locale/poisonivy.es.tr b/poisonivy/locale/poisonivy.es.tr index 19aaa3f..58f2f21 100644 --- a/poisonivy/locale/poisonivy.es.tr +++ b/poisonivy/locale/poisonivy.es.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Carlos Barraza , 2017. -# - Poison ivy (seedling)=Hiedra venenosa (retoño) Poison ivy (sproutling)=Hiedra venenosa (brotes) Poison ivy (climbing plant)=Hiedra venenosa (planta trepadora) -[Poison Ivy] Loaded.=[Poison Ivy] Cargado. diff --git a/poisonivy/locale/poisonivy.fr.tr b/poisonivy/locale/poisonivy.fr.tr index 1436b0d..519648e 100644 --- a/poisonivy/locale/poisonivy.fr.tr +++ b/poisonivy/locale/poisonivy.fr.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Poison ivy (seedling)=Sumac vénéneux (semis) Poison ivy (sproutling)=Sumac vénéneux (pousse) Poison ivy (climbing plant)=Sumac vénéneux (grimpant) -[Poison Ivy] Loaded.=[Poison Ivy] chargé. diff --git a/poisonivy/locale/poisonivy.pt.tr b/poisonivy/locale/poisonivy.pt.tr index 5b6ab87..9ef066d 100644 --- a/poisonivy/locale/poisonivy.pt.tr +++ b/poisonivy/locale/poisonivy.pt.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Poison ivy (seedling)=Hera venenosa (plantilha) Poison ivy (sproutling)=Hera venenosa (brotando) Poison ivy (climbing plant)=Hera venenosa (planta trepadeira) -[Poison Ivy] Loaded.=[Poison Ivy] Carregado diff --git a/poisonivy/locale/poisonivy.pt_BR.tr b/poisonivy/locale/poisonivy.pt_BR.tr index 185ddc9..d158d7c 100644 --- a/poisonivy/locale/poisonivy.pt_BR.tr +++ b/poisonivy/locale/poisonivy.pt_BR.tr @@ -1,6 +1,4 @@ # textdomain: poisonivy - -Poison ivy (seedling) = Hera venenosa (plantilha) -Poison ivy (sproutling) = Hera venenosa (brotando) -Poison ivy (climbing plant) = Hera venenosa (planta trepadeira) -[Poison Ivy] Loaded. =[Poison Ivy] Carregado +Poison ivy (seedling)= +Poison ivy (sproutling)= +Poison ivy (climbing plant)= diff --git a/poisonivy/locale/poisonivy.tr.tr b/poisonivy/locale/poisonivy.tr.tr index ecbb279..0e12f01 100644 --- a/poisonivy/locale/poisonivy.tr.tr +++ b/poisonivy/locale/poisonivy.tr.tr @@ -1,12 +1,4 @@ # textdomain: poisonivy - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# mahmutelmas06@hotmail.com, 2017. -# - Poison ivy (seedling)=Sarmaşık (Fidan) Poison ivy (sproutling)=Sarmaşık (Filiz) Poison ivy (climbing plant)=Sarmaşık (Dolanan) -[Poison Ivy] Loaded.=[Poison Ivy] yüklendi. diff --git a/poisonivy/locale/template.txt b/poisonivy/locale/template.txt new file mode 100644 index 0000000..d158d7c --- /dev/null +++ b/poisonivy/locale/template.txt @@ -0,0 +1,4 @@ +# textdomain: poisonivy +Poison ivy (seedling)= +Poison ivy (sproutling)= +Poison ivy (climbing plant)= diff --git a/trunks/generating.lua b/trunks/generating.lua index 145a945..2322062 100644 --- a/trunks/generating.lua +++ b/trunks/generating.lua @@ -475,8 +475,6 @@ end if Roots == true then -- see settings.txt abstract_trunks.grow_roots = function(pos) - local twig_size = math.random(1,27) - local right_here = {x=pos.x , y=pos.y , z=pos.z } local below = {x=pos.x , y=pos.y-1, z=pos.z } local north = {x=pos.x , y=pos.y , z=pos.z+1} diff --git a/trunks/init.lua b/trunks/init.lua index a82f7e3..729ed13 100644 --- a/trunks/init.lua +++ b/trunks/init.lua @@ -1,20 +1,8 @@ ------------------------------------------------------------------------------------------------ -local title = "Trunks" -local version = "0.1.4" -local mname = "trunks" ------------------------------------------------------------------------------------------------ -- Code by Mossmanikin & Neuromancer abstract_trunks = {} --- support for i18n -local S = minetest.get_translator("trunks") - dofile(minetest.get_modpath("trunks").."/trunks_settings.txt") dofile(minetest.get_modpath("trunks").."/generating.lua") dofile(minetest.get_modpath("trunks").."/nodes.lua") dofile(minetest.get_modpath("trunks").."/crafting.lua") - ------------------------------------------------------------------------------------------------ -print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...") ------------------------------------------------------------------------------------------------ diff --git a/trunks/locale/template.txt b/trunks/locale/template.txt index 50cbff1..3657950 100644 --- a/trunks/locale/template.txt +++ b/trunks/locale/template.txt @@ -1,11 +1,4 @@ # textdomain: trunks - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Twig= Moss= Moss with Fungus= diff --git a/trunks/locale/trunks.de.tr b/trunks/locale/trunks.de.tr index 54312be..f3ff6a5 100644 --- a/trunks/locale/trunks.de.tr +++ b/trunks/locale/trunks.de.tr @@ -1,11 +1,4 @@ # textdomain: trunks - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Twig=Zweig Moss=Moos Moss with Fungus=Moos mit Pilz diff --git a/trunks/locale/trunks.eo.tr b/trunks/locale/trunks.eo.tr index 5f43812..2e9255c 100644 --- a/trunks/locale/trunks.eo.tr +++ b/trunks/locale/trunks.eo.tr @@ -1,11 +1,4 @@ # textdomain: trunks - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Twig=Branĉeto Moss=Musko Moss with Fungus=Musko kun Fungo diff --git a/trunks/locale/trunks.fr.tr b/trunks/locale/trunks.fr.tr index 4ef3392..097c2bb 100644 --- a/trunks/locale/trunks.fr.tr +++ b/trunks/locale/trunks.fr.tr @@ -1,11 +1,4 @@ # textdomain: trunks - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Twig=Brindille Moss=Mousse Moss with Fungus=Mousse et champignons diff --git a/trunks/nodes.lua b/trunks/nodes.lua index 73cd9a1..f88df72 100644 --- a/trunks/nodes.lua +++ b/trunks/nodes.lua @@ -46,7 +46,7 @@ for i in pairs(NoDe) do if not placer then return end local playername = placer:get_player_name() - if minetest.is_protected(pt.above, playername) then + if minetest.is_protected(pt.above, playername) then minetest.record_protection_violation(pt.above, playername) return end @@ -125,7 +125,7 @@ for r = 0, 3 do }) end -minetest.register_alias("trunks:moss_plain", "trunks:moss_plain_0") +minetest.register_alias("trunks:moss_plain", "trunks:moss_plain_0") minetest.register_alias("trunks:moss_with_fungus", "trunks:moss_with_fungus_0") ----------------------------------------------------------------------------------------------- @@ -186,7 +186,7 @@ minetest.register_node("trunks:twigs_roof", { ----------------------------------------------------------------------------------------------- -- TWiGS RooF CoRNeR ----------------------------------------------------------------------------------------------- -minetest.register_alias("woodstuff:twigs_roof_corner", "trunks:twigs_roof_corner") +minetest.register_alias("woodstuff:twigs_roof_corner", "trunks:twigs_roof_corner") minetest.register_node("trunks:twigs_roof_corner", { description = S("Twigs Roof Corner 1"), @@ -214,7 +214,7 @@ minetest.register_node("trunks:twigs_roof_corner", { ----------------------------------------------------------------------------------------------- -- TWiGS RooF CoRNeR 2 ----------------------------------------------------------------------------------------------- -minetest.register_alias("woodstuff:twigs_roof_corner_2", "trunks:twigs_roof_corner_2") +minetest.register_alias("woodstuff:twigs_roof_corner_2", "trunks:twigs_roof_corner_2") minetest.register_node("trunks:twigs_roof_corner_2", { description = S("Twigs Roof Corner 2"), diff --git a/vines/locale/template.txt b/vines/locale/template.txt index c8c1a01..43ba2d9 100644 --- a/vines/locale/template.txt +++ b/vines/locale/template.txt @@ -1,10 +1,4 @@ # textdomain: vines - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# Vines= Matured= Rope= diff --git a/vines/locale/vines.de.tr b/vines/locale/vines.de.tr index 31c542e..81c6cda 100644 --- a/vines/locale/vines.de.tr +++ b/vines/locale/vines.de.tr @@ -1,10 +1,4 @@ # textdomain: vines - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# Vines=Ranken Matured=Gereifte Rope=Seil diff --git a/vines/locale/vines.eo.tr b/vines/locale/vines.eo.tr index cb6ce20..12018c2 100644 --- a/vines/locale/vines.eo.tr +++ b/vines/locale/vines.eo.tr @@ -1,10 +1,4 @@ # textdomain: vines - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# Vines=Vitoj Matured=Maturita Rope=Ŝnuro diff --git a/vines/locale/vines.fr.tr b/vines/locale/vines.fr.tr index 5610071..70c7dc1 100644 --- a/vines/locale/vines.fr.tr +++ b/vines/locale/vines.fr.tr @@ -1,11 +1,4 @@ # textdomain: vines - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Vines=Plantes grimpantes Matured=Extrémité de Rope=Corde diff --git a/woodsoils/init.lua b/woodsoils/init.lua index 5d65837..456ec30 100644 --- a/woodsoils/init.lua +++ b/woodsoils/init.lua @@ -1,32 +1,4 @@ ------------------------------------------------------------------------------------------------ -local title = "Wood Soils" -- former "Forest Soils" -local version = "0.0.9" -local mname = "woodsoils" -- former "forestsoils" ------------------------------------------------------------------------------------------------ - abstract_woodsoils = {} --- support for i18n -local S = minetest.get_translator("woodsoils") - dofile(minetest.get_modpath("woodsoils").."/nodes.lua") dofile(minetest.get_modpath("woodsoils").."/generating.lua") - --- felt like playing a bit :D ---[[print(" _____ __") -print("_/ ____\\___________ ____ _______/ |_") -print("\\ __\\/ _ \\_ __ \\_/ __ \\ / ___/\\ __\\") -print(" | | ( <_> ) | \\/\\ ___/ \\___ \\ | |") -print(" |__| \\____/|__| \\___ >____ > |__|") -print(" \\/ \\/") - -print(" .__.__") -print(" __________ |__| | ______") -print(" / ___/ _ \\| | | / ___/") -print(" \\___ ( <_> ) | |__\\___ \\") -print("/____ >____/|__|____/____ >") -print(" \\/ \\/")]] - ------------------------------------------------------------------------------------------------ -print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...") ------------------------------------------------------------------------------------------------ diff --git a/woodsoils/locale/template.txt b/woodsoils/locale/template.txt index 9c40b2a..e1ce367 100644 --- a/woodsoils/locale/template.txt +++ b/woodsoils/locale/template.txt @@ -1,11 +1,4 @@ # textdomain: woodsoils - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Forest Soil 1= Forest Soil 2= Forest Soil 3= diff --git a/woodsoils/locale/woodsoils.de.tr b/woodsoils/locale/woodsoils.de.tr index c30a2ce..c87d1b5 100644 --- a/woodsoils/locale/woodsoils.de.tr +++ b/woodsoils/locale/woodsoils.de.tr @@ -1,11 +1,4 @@ # textdomain: woodsoils - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Forest Soil 1=Waldboden 1 Forest Soil 2=Waldboden 2 Forest Soil 3=Waldboden 3 diff --git a/woodsoils/locale/woodsoils.eo.tr b/woodsoils/locale/woodsoils.eo.tr index 5998e30..8905184 100644 --- a/woodsoils/locale/woodsoils.eo.tr +++ b/woodsoils/locale/woodsoils.eo.tr @@ -1,11 +1,4 @@ # textdomain: woodsoils - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Forest Soil 1=Arbara Grundo 1 Forest Soil 2=Arbara Grundo 2 Forest Soil 3=Arbara Grundo 3 diff --git a/woodsoils/locale/woodsoils.fr.tr b/woodsoils/locale/woodsoils.fr.tr index 3ef6a2c..a9e756e 100644 --- a/woodsoils/locale/woodsoils.fr.tr +++ b/woodsoils/locale/woodsoils.fr.tr @@ -1,11 +1,4 @@ # textdomain: woodsoils - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Forest Soil 1=Humus forestier 1 Forest Soil 2=Humus forestier 2 Forest Soil 3=Humus forestier 3 diff --git a/youngtrees/locale/template.txt b/youngtrees/locale/template.txt index 745f6b8..33048ea 100644 --- a/youngtrees/locale/template.txt +++ b/youngtrees/locale/template.txt @@ -1,11 +1,4 @@ # textdomain: youngtrees - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# - Young Bamboo Tree= Young Tree 2 (middle)= Young Tree (top)= diff --git a/youngtrees/locale/youngtrees.de.tr b/youngtrees/locale/youngtrees.de.tr index d09f2ed..0024f8e 100644 --- a/youngtrees/locale/youngtrees.de.tr +++ b/youngtrees/locale/youngtrees.de.tr @@ -1,11 +1,4 @@ # textdomain: youngtrees - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# reusityback, 2022. -# - Young Bamboo Tree=Junger Bambus Young Tree 2 (middle)=Strauch 2 (Mitte) Young Tree (top)=Strauch (Spitze) diff --git a/youngtrees/locale/youngtrees.eo.tr b/youngtrees/locale/youngtrees.eo.tr index 5bf8f39..3aeca86 100644 --- a/youngtrees/locale/youngtrees.eo.tr +++ b/youngtrees/locale/youngtrees.eo.tr @@ -1,11 +1,4 @@ # textdomain: youngtrees - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# Jolesh, 2022. -# - Young Bamboo Tree=Juna Bambuarbo Young Tree 2 (middle)=Juna Arbo 2 (mezo) Young Tree (top)=Juna Arbo (supro) diff --git a/youngtrees/locale/youngtrees.fr.tr b/youngtrees/locale/youngtrees.fr.tr index 42de95b..19d9533 100644 --- a/youngtrees/locale/youngtrees.fr.tr +++ b/youngtrees/locale/youngtrees.fr.tr @@ -1,11 +1,4 @@ # textdomain: youngtrees - -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# fat115 , 2017. -# - Young Bamboo Tree=Bambou jeune Young Tree 2 (middle)=Arbuste 2 (milieu) Young Tree (top)=Arbuste (haut) From f4185762d5fc8939e1ef7a0bf92b0750ac485356 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Fri, 14 Jul 2023 13:07:24 +0200 Subject: [PATCH 06/25] Some minor German translation fixes (#47) --- bushes_classic/locale/bushes_classic.de.tr | 14 +++++++------- dryplants/locale/dryplants.de.tr | 4 ++-- pl_seaweed/locale/pl_seaweed.de.tr | 2 +- poisonivy/locale/poisonivy.de.tr | 4 ++-- trunks/locale/trunks.de.tr | 2 +- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/bushes_classic/locale/bushes_classic.de.tr b/bushes_classic/locale/bushes_classic.de.tr index 9d45852..727b0b2 100644 --- a/bushes_classic/locale/bushes_classic.de.tr +++ b/bushes_classic/locale/bushes_classic.de.tr @@ -3,37 +3,37 @@ Sugar=Zucker Strawberry=Erdbeere Raw Strawberry pie=Rohe Erdbeertorte Cooked Strawberry pie=Erdbeertorte -Slice of Strawberry pie=Erdbeertortenstueck +Slice of Strawberry pie=Erdbeertortenstück Basket with Strawberry pies=Korb mit Erdbeertorten Strawberry Bush=Erdbeerbusch Blackberry=Brombeere Raw Blackberry pie=Rohe Brombeertorte Cooked Blackberry pie=Brombeertorte -Slice of Blackberry pie=Brombeertortenstueck +Slice of Blackberry pie=Brombeertortenstück Basket with Blackberry pies=Korb mit Brombeertorten Blackberry Bush=Brombeerbusch Blueberry=Blaubeere Raw Blueberry pie=Rohe Blaubeertorte Cooked Blueberry pie=Blaubeertorte -Slice of Blueberry pie=Blaubeertortenstueck +Slice of Blueberry pie=Blaubeertortenstück Basket with Blueberry pies=Korb mit Blaubeertorten Blueberry Bush=Blaubeerbusch Raspberry=Himbeere Raw Raspberry pie=Rohe Himbeertorte Cooked Raspberry pie=Himbeertorte -Slice of Raspberry pie=Himbeertortenstueck +Slice of Raspberry pie=Himbeertortenstück Basket with Raspberry pies=Korb mit Himbeertorten Raspberry Bush=Himbeerbusch Gooseberry=Stachelbeere Raw Gooseberry pie=Rohe Stachelbeertorte Cooked Gooseberry pie=Stachelbeertorte -Slice of Gooseberry pie=Stachelbeertortenstueck +Slice of Gooseberry pie=Stachelbeertortenstück Basket with Gooseberry pies=Korb mit Stachelbeertorten Gooseberry Bush=Stachelbeerbusch Mixed Berry=Beerenmix Raw Mixed Berry pie=Rohe Beerenmixtorte Cooked Mixed Berry pie=Beerenmixtorte -Slice of Mixed Berry pie=Beerenmixtortenstueck +Slice of Mixed Berry pie=Beerenmixtortenstück Basket with Mixed Berry pies=Korb mit Beerenmixtorten -Currently fruitless Bush=zur Zeit fruechteloser +Currently fruitless Bush=Zur Zeit früchteloser Busch Basket=Korb diff --git a/dryplants/locale/dryplants.de.tr b/dryplants/locale/dryplants.de.tr index 8f5dff9..793a2d7 100644 --- a/dryplants/locale/dryplants.de.tr +++ b/dryplants/locale/dryplants.de.tr @@ -1,11 +1,11 @@ # textdomain: dryplants Sickle=Sichel -Cut Grass=Gras schneiden +Cut Grass=Grasschnitt Hay=Heu Short Grass=Kurzes Gras Juncus=Binsen Wet Reed=Nasses Schilf -Wet Reed Slab=Nasse Schilfstufe +Wet Reed Slab=Nasse Schilfplatte Wet Reed Roof=Nasses Schilfdach Wet Reed Roof Corner=Nasser Schilfdachwinkel Wet Reed Roof Corner 2=Nasser Schilfdachwinkel 2 diff --git a/pl_seaweed/locale/pl_seaweed.de.tr b/pl_seaweed/locale/pl_seaweed.de.tr index 6c34f92..989d7c0 100644 --- a/pl_seaweed/locale/pl_seaweed.de.tr +++ b/pl_seaweed/locale/pl_seaweed.de.tr @@ -1,2 +1,2 @@ # textdomain: pl_seaweed -Seaweed=Seetang +Seaweed=Seegras diff --git a/poisonivy/locale/poisonivy.de.tr b/poisonivy/locale/poisonivy.de.tr index 4b337a2..5a678a5 100644 --- a/poisonivy/locale/poisonivy.de.tr +++ b/poisonivy/locale/poisonivy.de.tr @@ -1,4 +1,4 @@ # textdomain: poisonivy -Poison ivy (seedling)=Giftefeu (Saemling) -Poison ivy (sproutling)=Giftefeu (Sproessling) +Poison ivy (seedling)=Giftefeu (Sämling) +Poison ivy (sproutling)=Giftefeu (Sprössling) Poison ivy (climbing plant)=Giftefeu (Kletterpflanze) diff --git a/trunks/locale/trunks.de.tr b/trunks/locale/trunks.de.tr index f3ff6a5..de83a5a 100644 --- a/trunks/locale/trunks.de.tr +++ b/trunks/locale/trunks.de.tr @@ -3,7 +3,7 @@ Twig=Zweig Moss=Moos Moss with Fungus=Moos mit Pilz Twigs Block=Zweigblock -Twigs Slab=Zweigstufe +Twigs Slab=Zweigplatte Twigs Roof=Zweigdach Twigs Roof Corner 1=Zweigdachwinkel 1 Twigs Roof Corner 2=Zweigdachwinkel 2 From e58042acd0e50b2737ec1ec33c744ab14f603f3d Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Sat, 15 Jul 2023 21:57:47 +0200 Subject: [PATCH 07/25] use degrotate for sunflowers (#49) --- pl_sunflowers/init.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pl_sunflowers/init.lua b/pl_sunflowers/init.lua index c7aaec8..a801ff8 100644 --- a/pl_sunflowers/init.lua +++ b/pl_sunflowers/init.lua @@ -15,7 +15,7 @@ minetest.register_node(":flowers:sunflower", { description = S("Sunflower"), drawtype = "mesh", paramtype = "light", - paramtype2 = "facedir", + paramtype2 = "degrotate", inventory_image = "flowers_sunflower_inv.png", mesh = "flowers_sunflower.obj", tiles = { "flowers_sunflower.png" }, @@ -44,7 +44,7 @@ minetest.register_decoration({ y_min = 1, y_max = 40, param2 = 0, - param2_max = 3, + param2_max = 239, place_on = { "default:dirt_with_grass" }, From ded2685047e9afc3f0f4316e08987ffe6bcbcd5d Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Wed, 19 Jul 2023 23:34:31 -0400 Subject: [PATCH 08/25] fix farming plus groups override --- bushes_classic/cooking.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bushes_classic/cooking.lua b/bushes_classic/cooking.lua index 9179f11..80d264d 100644 --- a/bushes_classic/cooking.lua +++ b/bushes_classic/cooking.lua @@ -33,7 +33,7 @@ end -- override farming_plus strawberry and add food_ group if minetest.get_modpath("farming_plus") then - local groups = table.copy(minetest.registered_items["farming_plus:strawberry_item"]) + local groups = table.copy(minetest.registered_items["farming_plus:strawberry_item"].groups) groups["food_strawberry"] = 1 groups["food_berry"] = 1 From 877d94dace90a15c1117207281a6ad5a3cb71c06 Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Fri, 21 Jul 2023 08:16:57 -0400 Subject: [PATCH 09/25] remove biomelib usage from youngtrees (#52) * remove biomelib usage from youngtrees * remove unneeded settingtypes.txt file now --- youngtrees/init.lua | 115 +++++++++++++++++++++--------------- youngtrees/mod.conf | 2 +- youngtrees/settingtypes.txt | 8 --- 3 files changed, 67 insertions(+), 58 deletions(-) delete mode 100644 youngtrees/settingtypes.txt diff --git a/youngtrees/init.lua b/youngtrees/init.lua index 586b5e4..9e02b3a 100644 --- a/youngtrees/init.lua +++ b/youngtrees/init.lua @@ -1,11 +1,5 @@ -- support for i18n local S = minetest.get_translator("youngtrees") -abstract_youngtrees = {} - -local youngtrees_youngtrees_rarity = tonumber(minetest.settings:get("youngtrees_youngtrees_rarity")) or 100 -local youngtrees_youngtrees_rarity_fertility = tonumber(minetest.settings:get("youngtrees_youngtrees_rarity_fertility")) or 0.5 -local youngtrees_youngtrees_fertility = tonumber(minetest.settings:get("youngtrees_youngtrees_fertility")) or -0.3 - minetest.register_node("youngtrees:bamboo", { description = S("Young Bamboo Tree"), @@ -99,52 +93,75 @@ minetest.register_node("youngtrees:youngtree_bottom", { type = "fixed", fixed = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3} }, + on_timer = function(pos, elapsed) + local function validateNode(node) + if not minetest.registered_nodes[node.name] or minetest.registered_nodes[node.name].drawtype ~= "airlike" then + return false + end + return true + end + + local onePos, twoPos = vector.new(pos.x, pos.y+1, pos.z), vector.new(pos.x, pos.y+2, pos.z) + local oneAbove, twoAbove = minetest.get_node_or_nil(onePos), minetest.get_node_or_nil(twoPos) + if not oneAbove or not twoAbove or not validateNode(oneAbove) or not validateNode(twoAbove) then + minetest.swap_node(pos, {name="air"}) + return + end + + if math.random() > 0.5 then + minetest.set_node(onePos, {name="youngtrees:youngtree_top"}) + else + minetest.set_node(onePos, {name="youngtrees:youngtree_middle"}) + minetest.set_node(twoPos, {name="youngtrees:youngtree_top"}) + end + end, groups = {snappy=3,flammable=2,attached_node=1}, sounds = default.node_sound_leaves_defaults(), drop = 'trunks:twig_1' }) - -abstract_youngtrees.grow_youngtree = function(pos) - local height = math.random(1,3) - abstract_youngtrees.grow_youngtree_node(pos,height) -end - - -abstract_youngtrees.grow_youngtree_node = function(pos, height) - local right_here = {x=pos.x, y=pos.y+1, z=pos.z} - local above_right_here = {x=pos.x, y=pos.y+2, z=pos.z} - - if minetest.get_node(right_here).name == "air" -- instead of check_air = true, - or minetest.get_node(right_here).name == "default:junglegrass" then - if height == 1 then - minetest.swap_node(right_here, {name="youngtrees:youngtree_top"}) - end - if height == 2 then - minetest.swap_node(right_here, {name="youngtrees:youngtree_bottom"}) - minetest.swap_node(above_right_here, {name="youngtrees:youngtree_top"}) - end - if height == 3 then - local two_above_right_here = {x=pos.x, y=pos.y+3, z=pos.z} - minetest.swap_node(right_here, {name="youngtrees:youngtree_bottom"}) - minetest.swap_node(above_right_here, {name="youngtrees:youngtree_middle"}) - minetest.swap_node(two_above_right_here, {name="youngtrees:youngtree_top"}) - end - end -end - - -biome_lib.register_on_generate({ - surface = { - "default:dirt_with_grass", - "stoneage:grass_with_silex", - "sumpf:peat", - "sumpf:sumpf" - }, - rarity = youngtrees_youngtrees_rarity, - rarity_fertility = youngtrees_youngtrees_rarity_fertility, - plantlife_limit = youngtrees_youngtrees_fertility, - min_elevation = 1, -- above sea level +minetest.register_decoration({ + name = "youngtrees:youngtree", + decoration = { + "youngtrees:youngtree_bottom" }, - abstract_youngtrees.grow_youngtree -) + fill_ratio = 0.0005, + y_min = 1, + y_max = 40, + param2 = 0, + param2_max = 3, + place_on = { + "default:dirt_with_grass", + "stoneage:grass_with_silex", + "sumpf:peat", + "sumpf:sumpf" + }, + deco_type = "simple", + flags = "all_floors", +}) + +--[[ + this is purposefully wrapped in a on mods loaded callback to that it gets the proper ids + if other mods clear the registered decorations +]] +local did +minetest.register_on_mods_loaded(function() + did = minetest.get_decoration_id("youngtrees:youngtree") + minetest.set_gen_notify("decoration", {did}) +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations = g["decoration#" .. did] or {} + for _, pos in pairs(deco_locations) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + local timer = minetest.get_node_timer({x=pos.x, y=pos.y+1, z=pos.z}) + timer:start(0) + end +end) \ No newline at end of file diff --git a/youngtrees/mod.conf b/youngtrees/mod.conf index 7de3928..b5b1250 100644 --- a/youngtrees/mod.conf +++ b/youngtrees/mod.conf @@ -1,2 +1,2 @@ name = youngtrees -depends = default, biome_lib +depends = default diff --git a/youngtrees/settingtypes.txt b/youngtrees/settingtypes.txt deleted file mode 100644 index d9e6cfd..0000000 --- a/youngtrees/settingtypes.txt +++ /dev/null @@ -1,8 +0,0 @@ -#Youngtree rarity % -youngtrees_youngtrees_rarity (Youngtree rarity %) float 100 0 100 - -#How much the rarity is reduced by fertility % -youngtrees_youngtrees_rarity_fertility (Youngtree rarity fertility reduction %) float 0.5 0 100 - -#Youngtree minimum fertility (-1 to +1) -youngtrees_youngtrees_fertility (Youngtree minimum fertility) float -0.3 -1 1 From 3b7fa4e8ea4061ae316f7a9dfab379e44bce5e8a Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Fri, 21 Jul 2023 11:06:06 -0400 Subject: [PATCH 10/25] alias obsolete item --- youngtrees/init.lua | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/youngtrees/init.lua b/youngtrees/init.lua index 9e02b3a..91c1bfe 100644 --- a/youngtrees/init.lua +++ b/youngtrees/init.lua @@ -21,28 +21,8 @@ minetest.register_node("youngtrees:bamboo", { drop = 'trunks:twig_1' }) -minetest.register_node("youngtrees:youngtree2_middle",{ - description = S("Young Tree 2 (middle)"), - drawtype="nodebox", - tiles = {"youngtree2branch.png"}, - use_texture_alpha = "clip", - inventory_image = "youngtree2branch.png", - wield_image = "youngtree2branch.png", - paramtype = "light", - walkable = false, - is_ground_content = true, - node_box = { - type = "fixed", - fixed = { - {0.125000,-0.500000,-0.500000,0.500000,-0.187500,-0.125000}, --NodeBox 1 - {-0.187500,-0.187500,-0.500000,0.500000,0.125000,0.250000}, --NodeBox 2 - {-0.500000,0.125000,-0.500000,0.500000,0.500000,0.500000}, --NodeBox 3 - } - }, - groups = {snappy=3,flammable=2,attached_node=1}, - sounds = default.node_sound_leaves_defaults(), - drop = 'trunks:twig_1' -}) + +minetest.register_alias("youngtrees:youngtree2_middle", "default:bush_stem") minetest.register_node("youngtrees:youngtree_top", { description = S("Young Tree (top)"), From 2af1d996d29622bb58d16558c5f9825f33a3b6de Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Fri, 21 Jul 2023 17:09:53 +0200 Subject: [PATCH 11/25] replace biome_lib ABM's (#48) * replace biome_lib ABM's * fix some params * remove 'group:flora' from poisonivy avoid list * fixes --- bushes_classic/init.lua | 52 ++++++++++++++++------ bushes_classic/mod.conf | 1 - ferns/horsetail.lua | 38 ++++++++++------ pl_seaweed/init.lua | 16 ++++--- pl_waterlilies/init.lua | 15 ++++--- poisonivy/init.lua | 99 ++++++++++++++++++++++++++++------------- poisonivy/mod.conf | 2 +- 7 files changed, 150 insertions(+), 73 deletions(-) diff --git a/bushes_classic/init.lua b/bushes_classic/init.lua index ff386cb..2918a5d 100644 --- a/bushes_classic/init.lua +++ b/bushes_classic/init.lua @@ -30,12 +30,19 @@ local modpath = minetest.get_modpath('bushes_classic') dofile(modpath..'/cooking.lua') dofile(modpath..'/nodes.lua') -biome_lib.register_active_spawner({ - spawn_delay = 3600, - spawn_plants = bushes_classic.spawn_list, - avoid_radius = 10, - spawn_chance = 100, - spawn_surfaces = { +local spawn_plants = bushes_classic.spawn_list + +local function get_biome_data(pos, perlin_fertile) + local fertility = perlin_fertile:get_2d({x=pos.x, y=pos.z}) + + local data = minetest.get_biome_data(pos) + -- Original values this method returned were +1 (lowest) to -1 (highest) + -- so we need to convert the 0-100 range from get_biome_data() to that. + return fertility, 1 - (data.heat / 100 * 2), 1 - (data.humidity / 100 * 2) +end + +minetest.register_abm({ + nodenames = { "default:dirt_with_grass", "woodsoils:dirt_with_leaves_1", "woodsoils:grass_with_leaves_1", @@ -43,14 +50,31 @@ biome_lib.register_active_spawner({ "farming:soil", "farming:soil_wet" }, - avoid_nodes = {"group:bush"}, - seed_diff = 545342534, -- chosen by a fair mashing of the keyboard - guaranteed to be random :P - plantlife_limit = -0.1, - light_min = 10, - temp_min = 0.15, -- approx 20C - temp_max = -0.15, -- approx 35C - humidity_min = 0, -- 50% RH - humidity_max = -1, -- 100% RH + interval = 3600, + chance = 100, + label = "[bushes_classic] spawn bushes", + min_y = -16, + max_y = 48, + action = function(pos, node) + local p_top = {x = pos.x, y = pos.y + 1, z = pos.z} + local n_top = minetest.get_node_or_nil(p_top) + if not n_top or n_top.name ~= "air" then return end + + local perlin_fertile_area = minetest.get_perlin(545342534, 3, 0.6, 100) + + local fertility, temperature, humidity = get_biome_data(pos, perlin_fertile_area) + + local pos_biome_ok = fertility > -0.1 and temperature <= 0.15 and temperature >= -0.15 and humidity <= 0 and humidity >= -1 + if not pos_biome_ok then return end + + if minetest.find_node_near(p_top, 10 + math.random(-1.5,2), {"group:bush"}) then + return -- Nodes to avoid are nearby + end + + local plant_to_spawn = spawn_plants[math.random(1, #spawn_plants)] + + minetest.swap_node(p_top, {name = plant_to_spawn, param2 = 0}) + end }) minetest.register_alias("bushes:basket_pies", "bushes:basket_strawberry") diff --git a/bushes_classic/mod.conf b/bushes_classic/mod.conf index 0adcd69..2a74a26 100644 --- a/bushes_classic/mod.conf +++ b/bushes_classic/mod.conf @@ -1,3 +1,2 @@ name = bushes_classic -depends = biome_lib optional_depends = farming, farming_plus diff --git a/ferns/horsetail.lua b/ferns/horsetail.lua index 3fefb04..f190b8b 100644 --- a/ferns/horsetail.lua +++ b/ferns/horsetail.lua @@ -75,13 +75,10 @@ create_nodes() -- Spawning ----------------------------------------------------------------------------------------------- if abstract_ferns.config.enable_horsetails_spawning == true then - biome_lib.register_active_spawner({ - spawn_delay = 1200, - spawn_plants = node_names, - spawn_chance = 400, - spawn_surfaces = { + minetest.register_abm({ + nodenames = { "default:dirt_with_grass", - "default:dirt_with_coniferous_litter", -- minetest >= 0.5 + "default:dirt_with_coniferous_litter", "default:desert_sand", "default:sand", "dryplants:grass_short", @@ -89,13 +86,28 @@ if abstract_ferns.config.enable_horsetails_spawning == true then "default:mossycobble", "default:gravel" }, - seed_diff = 329, - min_elevation = 1, -- above sea level - near_nodes = {"default:water_source","default:river_water_source","default:gravel"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, - --random_facedir = { 0, 179 }, + interval = 1200, + chance = 400, + label = "[ferns] spawn horsetails", + min_y = 1, + max_y = 48, + action = function(pos, node) + local p_top = {x = pos.x, y = pos.y + 1, z = pos.z} + local n_top = minetest.get_node_or_nil(p_top) + if not n_top or n_top.name ~= "air" then return end + + local NEAR_DST = 2 + if #minetest.find_nodes_in_area( + {x=pos.x-NEAR_DST, y=pos.y-1, z=pos.z-NEAR_DST}, + {x=pos.x+NEAR_DST, y=pos.y+1, z=pos.z+NEAR_DST}, + {"default:water_source","default:river_water_source","default:gravel"} + ) < 1 then return + end + + local plant_to_spawn = node_names[math.random(1, #node_names)] + + minetest.swap_node(p_top, {name = plant_to_spawn, param2 = 0}) + end }) end diff --git a/pl_seaweed/init.lua b/pl_seaweed/init.lua index e842478..b5456c7 100644 --- a/pl_seaweed/init.lua +++ b/pl_seaweed/init.lua @@ -6,6 +6,9 @@ pl_seaweed = {} local seaweed_max_count = tonumber(minetest.settings:get("pl_seaweed_max_count")) or 320 local seaweed_rarity = tonumber(minetest.settings:get("pl_seaweed_rarity")) or 33 +local function get_ndef(name) + return minetest.registered_nodes[name] or {} +end local algae_list = { {nil}, {2}, {3}, {4} } @@ -59,22 +62,21 @@ for i in ipairs(algae_list) do local under_node = minetest.get_node(pt.under) local above_node = minetest.get_node(pt.above) local top_node = minetest.get_node(top_pos) - - if biome_lib.get_nodedef_field(under_node.name, "buildable_to") then + if get_ndef(under_node.name)["buildable_to"] then if under_node.name ~= "default:water_source" then place_pos = pt.under - elseif top_node.name ~= "default:water_source" - and biome_lib.get_nodedef_field(top_node.name, "buildable_to") then + elseif top_node.name ~= "default:water_source" and get_ndef(top_node.name)["buildable_to"] then place_pos = top_pos else return end - elseif biome_lib.get_nodedef_field(above_node.name, "buildable_to") then + elseif get_ndef(above_node.name)["buildable_to"] then place_pos = pt.above end if not place_pos then return end -- something went wrong :P - if not minetest.is_protected(place_pos, placer:get_player_name()) then + local pname = placer:get_player_name() + if not minetest.is_protected(place_pos, pname) then local nodename = "default:cobble" -- :D @@ -96,7 +98,7 @@ for i in ipairs(algae_list) do minetest.swap_node(place_pos, {name = "flowers:seaweed", param2 = fdir}) end - if not biome_lib.expect_infinite_stacks then + if not minetest.is_creative_enabled(pname) then itemstack:take_item() end return itemstack diff --git a/pl_waterlilies/init.lua b/pl_waterlilies/init.lua index 1a33cbb..491a39a 100644 --- a/pl_waterlilies/init.lua +++ b/pl_waterlilies/init.lua @@ -6,6 +6,9 @@ pl_waterlilies = {} local lilies_max_count = tonumber(minetest.settings:get("pl_waterlilies_max_count")) or 320 local lilies_rarity = tonumber(minetest.settings:get("pl_waterlilies_rarity")) or 33 +local function get_ndef(name) + return minetest.registered_nodes[name] or {} +end local lilies_list = { { nil , nil , 1 }, @@ -72,20 +75,20 @@ for i in ipairs(lilies_list) do local above_node = minetest.get_node(pt.above) local top_node = minetest.get_node(top_pos) - if biome_lib.get_nodedef_field(under_node.name, "buildable_to") then + if get_ndef(under_node.name)["buildable_to"] then if under_node.name ~= "default:water_source" then place_pos = pt.under - elseif top_node.name ~= "default:water_source" - and biome_lib.get_nodedef_field(top_node.name, "buildable_to") then + elseif top_node.name ~= "default:water_source" and get_ndef(top_node.name)["buildable_to"] then place_pos = top_pos else return end - elseif biome_lib.get_nodedef_field(above_node.name, "buildable_to") then + elseif get_ndef(above_node.name)["buildable_to"] then place_pos = pt.above end - if place_pos and not minetest.is_protected(place_pos, placer:get_player_name()) then + local pname = placer:get_player_name() + if place_pos and not minetest.is_protected(place_pos, pname) then local nodename = "default:cobble" -- if this block appears, something went....wrong :-) @@ -114,7 +117,7 @@ for i in ipairs(lilies_list) do minetest.swap_node(place_pos, {name = "flowers:waterlily", param2 = fdir}) end - if not biome_lib.expect_infinite_stacks then + if not minetest.is_creative_enabled(pname) then itemstack:take_item() end return itemstack diff --git a/poisonivy/init.lua b/poisonivy/init.lua index f0e9d9d..a1d33b3 100644 --- a/poisonivy/init.lua +++ b/poisonivy/init.lua @@ -3,11 +3,6 @@ -- support for i18n local S = minetest.get_translator("poisonivy") -local SPAWN_DELAY = 1000 -local SPAWN_CHANCE = 200 -local GROW_DELAY = 500 -local GROW_CHANCE = 30 -local poisonivy_seed_diff = 339 local walls_list = { "default:dirt", "default:dirt_with_grass", @@ -69,33 +64,75 @@ minetest.register_node('poisonivy:climbing', { buildable_to = true, }) -biome_lib.register_active_spawner({ - spawn_delay = SPAWN_DELAY, - spawn_plants = {"poisonivy:seedling"}, - avoid_radius = 10, - spawn_chance = SPAWN_CHANCE/10, - spawn_surfaces = {"default:dirt_with_grass"}, - avoid_nodes = {"group:poisonivy", "group:flower", "group:flora"}, - seed_diff = poisonivy_seed_diff, - light_min = 7, - alt_wallnode = "poisonivy:climbing", - verticals_list = walls_list +local function find_adjacent_wall(pos, verticals, randomflag) + local verts = dump(verticals) + + if string.find(verts, minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }).name) then return 3 end + if string.find(verts, minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }).name) then return 2 end + if string.find(verts, minetest.get_node({x=pos.x , y=pos.y, z=pos.z-1}).name) then return 5 end + if string.find(verts, minetest.get_node({x=pos.x , y=pos.y, z=pos.z+1}).name) then return 4 end + + return nil +end + +minetest.register_abm({ + nodenames = {"default:dirt_with_grass"}, + interval = 1000, + chance = 20, + label = "[poisoninvy] spawn plants", + min_y = -16, + max_y = 48, + action = function(pos, node) + local p_top = {x = pos.x, y = pos.y + 1, z = pos.z} + local n_top = minetest.get_node_or_nil(p_top) + if not n_top or n_top.name ~= "air" then return end + + local n_light = minetest.get_node_light(p_top) + if n_light < 7 then + return + end + + if minetest.find_node_near(p_top, 10 + math.random(-1.5,2), {"group:poisonivy", "group:flower"}) then + return -- Nodes to avoid are nearby + end + + local walldir = find_adjacent_wall(p_top, walls_list) + if walldir then + minetest.swap_node(p_top, {name = "poisonivy:climbing", param2 = walldir}) + return + end + + minetest.swap_node(p_top, {name = "poisonivy:seedling", param2 = 0}) + end }) -biome_lib.update_plant({ - grow_delay = SPAWN_DELAY, - grow_chance = GROW_CHANCE, - grow_plant = "poisonivy:seedling", - grow_result = "poisonivy:sproutling", - grow_nodes = {"default:dirt_with_grass"} +minetest.register_abm({ + nodenames = {"poisonivy:seedling"}, + interval = 1000, + chance = 30, + label = "grow poisonivy", + action = function(pos, node) + local p_top = {x=pos.x, y=pos.y+1, z=pos.z} + local n_top = minetest.get_node(p_top) + + if n_top.name == "air" then + minetest.swap_node(pos, {name = "poisonivy:sproutling"}) + end + end }) -biome_lib.update_plant({ - grow_delay = GROW_DELAY, - grow_chance = GROW_CHANCE*2, - grow_plant = "poisonivy:climbing", - need_wall = true, - grow_vertically = true, - verticals_list = walls_list, - ground_nodes = {"default:dirt_with_grass"} -}) +minetest.register_abm({ + nodenames = {"poisonivy:climbing"}, + interval = 500, + chance = 60, + label = "grow climbing poisonivy", + action = function(pos, node) + local p_top = {x=pos.x, y=pos.y+1, z=pos.z} + local n_top = minetest.get_node(p_top) + + local walldir = find_adjacent_wall(p_top, walls_list) + if n_top.name == "air" and walldir then + minetest.swap_node(p_top, {name = "poisonivy:climbing", param2 = walldir}) + end + end +}) \ No newline at end of file diff --git a/poisonivy/mod.conf b/poisonivy/mod.conf index 7819d1e..da42df7 100644 --- a/poisonivy/mod.conf +++ b/poisonivy/mod.conf @@ -1,2 +1,2 @@ name = poisonivy -depends = biome_lib +depends = default From 12cfbe3cb58dcf16e39a66906b9b30e065a3d554 Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Fri, 21 Jul 2023 15:29:53 -0400 Subject: [PATCH 12/25] Luacheck things (#53) * add luacheck workflow * get rid of ancient settings in dryplants * toss settings.txt code file * get rid of settings in trunks * Update .github/workflows/luacheck.yml Co-authored-by: SX <50966843+S-S-X@users.noreply.github.com> --------- Co-authored-by: OgelGames Co-authored-by: SX <50966843+S-S-X@users.noreply.github.com> --- .github/workflows/luacheck.yml | 13 +++ .luacheckrc | 25 +++-- dryplants/init.lua | 23 ++-- dryplants/juncus.lua | 8 +- dryplants/moregrass.lua | 4 +- dryplants/reed.lua | 200 ++++++++++++++++----------------- dryplants/reedmace.lua | 16 +-- dryplants/settings.txt | 52 --------- trunks/generating.lua | 41 ++----- trunks/init.lua | 3 +- trunks/nodes.lua | 150 ++++++++++++------------- trunks/trunks_settings.txt | 70 ------------ 12 files changed, 236 insertions(+), 369 deletions(-) create mode 100644 .github/workflows/luacheck.yml delete mode 100644 dryplants/settings.txt delete mode 100644 trunks/trunks_settings.txt diff --git a/.github/workflows/luacheck.yml b/.github/workflows/luacheck.yml new file mode 100644 index 0000000..50995e1 --- /dev/null +++ b/.github/workflows/luacheck.yml @@ -0,0 +1,13 @@ +name: luacheck +on: [push, pull_request] +jobs: + luacheck: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - name: apt + run: sudo apt-get install -y luarocks + - name: luacheck install + run: luarocks install --local luacheck + - name: luacheck run + run: $HOME/.luarocks/bin/luacheck ./ diff --git a/.luacheckrc b/.luacheckrc index 3443394..549462d 100644 --- a/.luacheckrc +++ b/.luacheckrc @@ -1,14 +1,21 @@ unused_args = false allow_defined_top = true +max_line_length = 185 -read_globals = { - "biome_lib", - "DIR_DELIM", - "minetest", "core", - "dump", - "vector", "nodeupdate", - "VoxelManip", "VoxelArea", - "PseudoRandom", "ItemStack", - "default", +exclude_files = {".luacheckrc"} + +globals = { + "biome_lib", "abstract_dryplants", + "bushes_classic", "abstract_trunks", } +read_globals = { + table = {fields = {"copy"}}, + + "minetest", "ItemStack", + "vector", + + "default", + "moretrees", + "dump", +} diff --git a/dryplants/init.lua b/dryplants/init.lua index a3256b9..11235e4 100644 --- a/dryplants/init.lua +++ b/dryplants/init.lua @@ -12,17 +12,12 @@ abstract_dryplants = {} local S = minetest.get_translator("dryplants") dofile(minetest.get_modpath("dryplants").."/crafting.lua") -dofile(minetest.get_modpath("dryplants").."/settings.txt") dofile(minetest.get_modpath("dryplants").."/reed.lua") -if REEDMACE_GENERATES == true then - dofile(minetest.get_modpath("dryplants").."/reedmace.lua") -end -if SMALL_JUNCUS_GENERATES == true then - dofile(minetest.get_modpath("dryplants").."/juncus.lua") -end -if EXTRA_TALL_GRASS_GENERATES == true then - dofile(minetest.get_modpath("dryplants").."/moregrass.lua") -end + +dofile(minetest.get_modpath("dryplants").."/reedmace.lua") +dofile(minetest.get_modpath("dryplants").."/juncus.lua") +dofile(minetest.get_modpath("dryplants").."/moregrass.lua") + --dofile(minetest.get_modpath("dryplants").."/meadowvariation.lua") ----------------------------------------------------------------------------------------------- @@ -140,7 +135,7 @@ minetest.register_node("dryplants:grass", { ----------------------------------------------------------------------------------------------- minetest.register_abm({ nodenames = {"dryplants:grass"}, - interval = HAY_DRYING_TIME, --1200, -- 20 minutes: a minetest-day/night-cycle + interval = 3600, --1200, -- 20 minutes: a minetest-day/night-cycle chance = 1, action = function(pos) minetest.swap_node(pos, {name="dryplants:hay"}) @@ -186,8 +181,8 @@ minetest.register_node("dryplants:grass_short", { ----------------------------------------------------------------------------------------------- minetest.register_abm({ nodenames = {"dryplants:grass_short"}, - interval = GRASS_REGROWING_TIME, --1200, -- 20 minutes: a minetest-day/night-cycle - chance = 100/GRASS_REGROWING_CHANCE, + interval = 1200, --1200, -- 20 minutes: a minetest-day/night-cycle + chance = 100/1200, action = function(pos) -- Only become dirt with grass if no cut grass or hay lies on top local above = minetest.get_node({x=pos.x, y=pos.y+1, z=pos.z}) @@ -196,3 +191,5 @@ minetest.register_abm({ end end, }) + +abstract_dryplants.loaded = true diff --git a/dryplants/juncus.lua b/dryplants/juncus.lua index 186b4b0..8c36092 100644 --- a/dryplants/juncus.lua +++ b/dryplants/juncus.lua @@ -105,8 +105,8 @@ biome_lib.register_on_generate({ "sumpf:peat", "sumpf:sumpf" }, - max_count = JUNCUS_NEAR_WATER_PER_MAPBLOCK, - rarity = 101 - JUNCUS_NEAR_WATER_RARITY, + max_count = 70, + rarity = 101 - 75, min_elevation = 1, -- above sea level near_nodes = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, near_nodes_size = 2, @@ -126,8 +126,8 @@ biome_lib.register_on_generate({ --"sumpf:peat", --"sumpf:sumpf" }, - max_count = JUNCUS_AT_BEACH_PER_MAPBLOCK, - rarity = 101 - JUNCUS_AT_BEACH_RARITY, + max_count = 70, + rarity = 101 - 75, min_elevation = 1, -- above sea level near_nodes = {"default:dirt_with_grass"}, near_nodes_size = 2, diff --git a/dryplants/moregrass.lua b/dryplants/moregrass.lua index e953c27..2f574a4 100644 --- a/dryplants/moregrass.lua +++ b/dryplants/moregrass.lua @@ -15,8 +15,8 @@ biome_lib.register_on_generate( "sumpf:peat", "sumpf:sumpf" }, - max_count = TALL_GRASS_PER_MAPBLOCK, - rarity = 101 - TALL_GRASS_RARITY, + max_count = 4800, + rarity = 101 - 75, min_elevation = 1, -- above sea level plantlife_limit = -0.9, check_air = true, diff --git a/dryplants/reed.lua b/dryplants/reed.lua index f80ffa5..1b7f0b3 100644 --- a/dryplants/reed.lua +++ b/dryplants/reed.lua @@ -75,99 +75,96 @@ minetest.register_node("dryplants:wetreed_roof", { sounds = default.node_sound_leaves_defaults(), }) -if AUTO_ROOF_CORNER == true then - - local CoRNeR = { +local CoRNeR = { -- MaTeRiaL - {"wetreed"}, - {"reed"} - } + {"wetreed"}, + {"reed"} +} - for i in pairs(CoRNeR) do +for i in pairs(CoRNeR) do - local MaTeRiaL = CoRNeR[i][1] - local roof = "dryplants:"..MaTeRiaL.."_roof" - local corner = "dryplants:"..MaTeRiaL.."_roof_corner" - local corner_2 = "dryplants:"..MaTeRiaL.."_roof_corner_2" + local MaTeRiaL = CoRNeR[i][1] + local roof = "dryplants:"..MaTeRiaL.."_roof" + local corner = "dryplants:"..MaTeRiaL.."_roof_corner" + local corner_2 = "dryplants:"..MaTeRiaL.."_roof_corner_2" - minetest.register_abm({ - nodenames = {roof}, - interval = 1, - chance = 1, - action = function(pos) + minetest.register_abm({ + nodenames = {roof}, + interval = 1, + chance = 1, + action = function(pos) - local node_east = minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }) - local node_west = minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }) - local node_north = minetest.get_node({x=pos.x, y=pos.y, z=pos.z+1}) - local node_south = minetest.get_node({x=pos.x, y=pos.y, z=pos.z-1}) - -- corner 1 - if ((node_west.name == roof and node_west.param2 == 0) - or (node_west.name == corner and node_west.param2 == 1)) - and ((node_north.name == roof and node_north.param2 == 3) - or (node_north.name == corner and node_north.param2 == 3)) - then - minetest.swap_node(pos, {name=corner, param2=0}) - end + local node_east = minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }) + local node_west = minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }) + local node_north = minetest.get_node({x=pos.x, y=pos.y, z=pos.z+1}) + local node_south = minetest.get_node({x=pos.x, y=pos.y, z=pos.z-1}) + -- corner 1 + if ((node_west.name == roof and node_west.param2 == 0) + or (node_west.name == corner and node_west.param2 == 1)) + and ((node_north.name == roof and node_north.param2 == 3) + or (node_north.name == corner and node_north.param2 == 3)) + then + minetest.swap_node(pos, {name=corner, param2=0}) + end - if ((node_north.name == roof and node_north.param2 == 1) - or (node_north.name == corner and node_north.param2 == 2)) - and ((node_east.name == roof and node_east.param2 == 0) - or (node_east.name == corner and node_east.param2 == 0)) - then - minetest.swap_node(pos, {name=corner, param2=1}) - end + if ((node_north.name == roof and node_north.param2 == 1) + or (node_north.name == corner and node_north.param2 == 2)) + and ((node_east.name == roof and node_east.param2 == 0) + or (node_east.name == corner and node_east.param2 == 0)) + then + minetest.swap_node(pos, {name=corner, param2=1}) + end - if ((node_east.name == roof and node_east.param2 == 2) - or (node_east.name == corner and node_east.param2 == 3)) - and ((node_south.name == roof and node_south.param2 == 1) - or (node_south.name == corner and node_south.param2 == 1)) - then - minetest.swap_node(pos, {name=corner, param2=2}) - end + if ((node_east.name == roof and node_east.param2 == 2) + or (node_east.name == corner and node_east.param2 == 3)) + and ((node_south.name == roof and node_south.param2 == 1) + or (node_south.name == corner and node_south.param2 == 1)) + then + minetest.swap_node(pos, {name=corner, param2=2}) + end - if ((node_south.name == roof and node_south.param2 == 3) - or (node_south.name == corner and node_south.param2 == 0)) - and ((node_west.name == roof and node_west.param2 == 2) - or (node_west.name == corner and node_west.param2 == 2)) - then - minetest.swap_node(pos, {name=corner, param2=3}) - end - -- corner 2 - if ((node_west.name == roof and node_west.param2 == 2) - or (node_west.name == corner_2 and node_west.param2 == 1)) - and ((node_north.name == roof and node_north.param2 == 1) - or (node_north.name == corner_2 and node_north.param2 == 3)) - then - minetest.swap_node(pos, {name=corner_2, param2=0}) - end + if ((node_south.name == roof and node_south.param2 == 3) + or (node_south.name == corner and node_south.param2 == 0)) + and ((node_west.name == roof and node_west.param2 == 2) + or (node_west.name == corner and node_west.param2 == 2)) + then + minetest.swap_node(pos, {name=corner, param2=3}) + end + -- corner 2 + if ((node_west.name == roof and node_west.param2 == 2) + or (node_west.name == corner_2 and node_west.param2 == 1)) + and ((node_north.name == roof and node_north.param2 == 1) + or (node_north.name == corner_2 and node_north.param2 == 3)) + then + minetest.swap_node(pos, {name=corner_2, param2=0}) + end - if ((node_north.name == roof and node_north.param2 == 3) - or (node_north.name == corner_2 and node_north.param2 == 2)) - and ((node_east.name == roof and node_east.param2 == 2) - or (node_east.name == corner_2 and node_east.param2 == 0)) - then - minetest.swap_node(pos, {name=corner_2, param2=1}) - end + if ((node_north.name == roof and node_north.param2 == 3) + or (node_north.name == corner_2 and node_north.param2 == 2)) + and ((node_east.name == roof and node_east.param2 == 2) + or (node_east.name == corner_2 and node_east.param2 == 0)) + then + minetest.swap_node(pos, {name=corner_2, param2=1}) + end - if ((node_east.name == roof and node_east.param2 == 0) - or (node_east.name == corner_2 and node_east.param2 == 3)) - and ((node_south.name == roof and node_south.param2 == 3) - or (node_south.name == corner_2 and node_south.param2 == 1)) - then - minetest.swap_node(pos, {name=corner_2, param2=2}) - end + if ((node_east.name == roof and node_east.param2 == 0) + or (node_east.name == corner_2 and node_east.param2 == 3)) + and ((node_south.name == roof and node_south.param2 == 3) + or (node_south.name == corner_2 and node_south.param2 == 1)) + then + minetest.swap_node(pos, {name=corner_2, param2=2}) + end - if ((node_south.name == roof and node_south.param2 == 1) - or (node_south.name == corner_2 and node_south.param2 == 0)) - and ((node_west.name == roof and node_west.param2 == 0) - or (node_west.name == corner_2 and node_west.param2 == 2)) - then - minetest.swap_node(pos, {name=corner_2, param2=3}) - end + if ((node_south.name == roof and node_south.param2 == 1) + or (node_south.name == corner_2 and node_south.param2 == 0)) + and ((node_west.name == roof and node_west.param2 == 0) + or (node_west.name == corner_2 and node_west.param2 == 2)) + then + minetest.swap_node(pos, {name=corner_2, param2=3}) + end - end, - }) - end + end, + }) end ----------------------------------------------------------------------------------------------- @@ -233,31 +230,28 @@ minetest.register_node("dryplants:wetreed_roof_corner_2", { ----------------------------------------------------------------------------------------------- -- Wet Reed becomes (dry) Reed over time ----------------------------------------------------------------------------------------------- -if REED_WILL_DRY == true then - - local DRyiNG = { +local DRyiNG = { -- WeT DRy - {"dryplants:wetreed", "dryplants:reed"}, - {"dryplants:wetreed_slab", "dryplants:reed_slab"}, - {"dryplants:wetreed_roof", "dryplants:reed_roof"}, - {"dryplants:wetreed_roof_corner", "dryplants:reed_roof_corner"}, - {"dryplants:wetreed_roof_corner_2", "dryplants:reed_roof_corner_2"} - } - for i in pairs(DRyiNG) do + {"dryplants:wetreed", "dryplants:reed"}, + {"dryplants:wetreed_slab", "dryplants:reed_slab"}, + {"dryplants:wetreed_roof", "dryplants:reed_roof"}, + {"dryplants:wetreed_roof_corner", "dryplants:reed_roof_corner"}, + {"dryplants:wetreed_roof_corner_2", "dryplants:reed_roof_corner_2"} +} +for i in pairs(DRyiNG) do - local WeT = DRyiNG[i][1] - local DRy = DRyiNG[i][2] + local WeT = DRyiNG[i][1] + local DRy = DRyiNG[i][2] - minetest.register_abm({ - nodenames = {WeT}, - interval = REED_DRYING_TIME, --1200, -- 20 minutes: a minetest-day/night-cycle - chance = 1, - action = function(pos) - local direction = minetest.get_node(pos).param2 - minetest.swap_node(pos, {name=DRy, param2=direction}) - end, - }) - end + minetest.register_abm({ + nodenames = {WeT}, + interval = 3600, --1200, -- 20 minutes: a minetest-day/night-cycle + chance = 1, + action = function(pos) + local direction = minetest.get_node(pos).param2 + minetest.swap_node(pos, {name=DRy, param2=direction}) + end, + }) end ----------------------------------------------------------------------------------------------- diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index 3c97f56..6d5ecda 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -276,8 +276,8 @@ minetest.register_node("dryplants:reedmace_sapling", { -- abm minetest.register_abm({ nodenames = "dryplants:reedmace_sapling", - interval = REEDMACE_GROWING_TIME, - chance = 100/REEDMACE_GROWING_CHANCE, + interval = 600, + chance = 100/5, action = function(pos, node, _, _) if string.find(minetest.get_node({x = pos.x + 1, y = pos.y, z = pos.z }).name, "default:water") or string.find(minetest.get_node({x = pos.x, y = pos.y, z = pos.z + 1}).name, "default:water") @@ -357,8 +357,8 @@ biome_lib.register_on_generate({ "sumpf:peat", "sumpf:sumpf" }, - max_count = REEDMACE_NEAR_WATER_PER_MAPBLOCK, - rarity = 101 - REEDMACE_NEAR_WATER_RARITY, + max_count = 35, + rarity = 101 - 40, --rarity = 60, min_elevation = 1, -- above sea level near_nodes = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, @@ -380,8 +380,8 @@ biome_lib.register_on_generate({ "sumpf:peat", "sumpf:sumpf" }, - max_count = REEDMACE_IN_WATER_PER_MAPBLOCK, - rarity = 101 - REEDMACE_IN_WATER_RARITY, + max_count = 35, + rarity = 101 - 65, --rarity = 35, min_elevation = 0, -- a bit below sea level max_elevation = 0, -- "" @@ -398,8 +398,8 @@ biome_lib.register_on_generate({ "default:sand", "sumpf:sumpf" }, - max_count = REEDMACE_FOR_OASES_PER_MAPBLOCK, - rarity = 101 - REEDMACE_FOR_OASES_RARITY, + max_count = 35, + rarity = 101 - 90, --rarity = 10, neighbors = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, ncount = 1, diff --git a/dryplants/settings.txt b/dryplants/settings.txt deleted file mode 100644 index cc12a9c..0000000 --- a/dryplants/settings.txt +++ /dev/null @@ -1,52 +0,0 @@ --- Here you can enable/disable the different plants -REEDMACE_GENERATES = true -SMALL_JUNCUS_GENERATES = true -EXTRA_TALL_GRASS_GENERATES = true - - - --- Amount of Reedmace near water or swamp -REEDMACE_NEAR_WATER_PER_MAPBLOCK = 35 -- plants per 80x80x80 nodes (absolute maximum number) -REEDMACE_NEAR_WATER_RARITY = 40 -- percent - --- Amount of Reedmace in water -REEDMACE_IN_WATER_PER_MAPBLOCK = 35 -- plants per 80x80x80 nodes (absolute maximum number) -REEDMACE_IN_WATER_RARITY = 65 -- percent - --- Amount of Reedmace for oases, tropical beaches and tropical swamps -REEDMACE_FOR_OASES_PER_MAPBLOCK = 35 -- plants per 80x80x80 nodes (absolute maximum number) -REEDMACE_FOR_OASES_RARITY = 90 -- percent - --- growing of reedmace sapling -REEDMACE_GROWING_TIME = 600 -- seconds -REEDMACE_GROWING_CHANCE = 5 -- percent - - - --- Amount of small Juncus near water or swamp -JUNCUS_NEAR_WATER_PER_MAPBLOCK = 70 -- plants per 80x80x80 nodes (absolute maximum number) -JUNCUS_NEAR_WATER_RARITY = 75 -- percent - --- Amount of small Juncus at dunes/beach -JUNCUS_AT_BEACH_PER_MAPBLOCK = 70 -- plants per 80x80x80 nodes (absolute maximum number) -JUNCUS_AT_BEACH_RARITY = 75 -- percent - - - --- Tall Grass on dirt with grass -TALL_GRASS_PER_MAPBLOCK = 4800 -- plants per 80x80x80 nodes (absolute maximum number) -TALL_GRASS_RARITY = 75 -- percent - - - --- short grass becomes dirt with grass again -GRASS_REGROWING_TIME = 1200 -- seconds -GRASS_REGROWING_CHANCE = 5 -- percent - -HAY_DRYING_TIME = 3600 -- seconds - -REED_WILL_DRY = false -- wet reed nodes will become dry reed nodes -REED_DRYING_TIME = 3600 -- seconds - -AUTO_ROOF_CORNER = true - diff --git a/trunks/generating.lua b/trunks/generating.lua index 2322062..0171eca 100644 --- a/trunks/generating.lua +++ b/trunks/generating.lua @@ -29,8 +29,6 @@ abstract_trunks.place_twig = function(pos) if twig_size <= 16 then minetest.swap_node(right_here, {name="trunks:twig_"..math.random(1,4), param2=math.random(0,3)}) end --- big twigs - if Big_Twigs == true then -- big twig 1 if twig_size == 17 then if not (check_node_buildable_to({x=pos.x+1,y=pos.y,z=pos.z+1}) @@ -148,14 +146,12 @@ abstract_trunks.place_twig = function(pos) elseif twig_size <= 25 then minetest.swap_node(right_here, {name="trunks:twig_"..math.random(12,13), param2=math.random(0,3)}) end - end end -if Twigs_on_ground == true then biome_lib.register_on_generate({ surface = {"default:dirt_with_grass"}, - max_count = Twigs_on_ground_Max_Count, - rarity = Twigs_on_ground_Rarity, + max_count = 640, + rarity = 66, min_elevation = 1, max_elevation = 40, near_nodes = {"group:tree","ferns:fern_03","ferns:fern_02","ferns:fern_01"}, @@ -166,13 +162,11 @@ biome_lib.register_on_generate({ }, abstract_trunks.place_twig ) -end -if Twigs_on_water == true then biome_lib.register_on_generate({ surface = {"default:water_source"}, - max_count = Twigs_on_water_Max_Count, - rarity = Twigs_on_water_Rarity, + max_count = 320, + rarity = 33, min_elevation = 1, max_elevation = 40, near_nodes = {"group:tree"}, @@ -183,7 +177,6 @@ biome_lib.register_on_generate({ }, abstract_trunks.place_twig ) -end ----------------------------------------------------------------------------------------------- -- TRuNKS @@ -211,7 +204,6 @@ local TRuNKS = { {"moretrees", "willow_trunk", 17}, } -if Horizontal_Trunks == true then -- see settings.txt for i in pairs(TRuNKS) do local MoD = TRuNKS[i][1] local TRuNK = TRuNKS[i][2] @@ -225,7 +217,6 @@ for i in pairs(TRuNKS) do minetest.register_node(":"..trunkname, temptrunk) end end -end abstract_trunks.place_trunk = function(pos) @@ -254,7 +245,7 @@ abstract_trunks.place_trunk = function(pos) else minetest.swap_node(right_here, {name="default:tree"}) end - elseif trunk_type == 2 and Horizontal_Trunks == true then + elseif trunk_type == 2 then if minetest.get_modpath(MoD) ~= nil then if check_node_buildable_to(north) then minetest.swap_node(north, {name=MoD..":"..TRuNK, param2=4}) @@ -286,7 +277,7 @@ abstract_trunks.place_trunk = function(pos) minetest.swap_node(south2, {name="default:tree", param2=4}) end end - elseif trunk_type == 3 and Horizontal_Trunks == true then + elseif trunk_type == 3 then if minetest.get_modpath(MoD) ~= nil then if check_node_buildable_to(west) then minetest.swap_node(west, {name=MoD..":"..TRuNK, param2=12}) @@ -324,8 +315,8 @@ end biome_lib.register_on_generate({ surface = {"default:dirt_with_grass"}, - max_count = Trunks_Max_Count, -- 320, - rarity = Trunks_Rarity, -- 99, + max_count = 320, -- 320, + rarity = 99, -- 99, min_elevation = 1, max_elevation = 40, avoid_nodes = {"group:tree"}, @@ -342,7 +333,6 @@ biome_lib.register_on_generate({ ----------------------------------------------------------------------------------------------- -- MoSS & FuNGuS -- on ground ----------------------------------------------------------------------------------------------- -if Moss_on_ground == true then abstract_trunks.grow_moss_on_ground = function(pos) local on_ground = {x=pos.x, y=pos.y+1, z=pos.z} local moss_type = math.random(1,21) @@ -358,8 +348,8 @@ end biome_lib.register_on_generate({ surface = {"default:dirt_with_grass"}, - max_count = Moss_on_ground_Max_Count, - rarity = Moss_on_ground_Rarity, + max_count = 400, + rarity = 79, min_elevation = 1, max_elevation = 40, near_nodes = { @@ -375,12 +365,10 @@ biome_lib.register_on_generate({ }, abstract_trunks.grow_moss_on_ground ) -end ----------------------------------------------------------------------------------------------- -- MoSS & FuNGuS -- on trunks ----------------------------------------------------------------------------------------------- -if Moss_on_trunk == true then abstract_trunks.grow_moss_on_trunk = function(pos) local on_ground = {x=pos.x, y=pos.y+1, z=pos.z} local at_side_n = {x=pos.x, y=pos.y, z=pos.z+1} @@ -458,8 +446,8 @@ biome_lib.register_on_generate({ "moretrees:willow_trunk", "default:mossycobble" }, - max_count = Moss_on_trunk_Max_Count, - rarity = Moss_on_trunk_Rarity, + max_count = 640, + rarity = 24, min_elevation = 1, max_elevation = 40, plantlife_limit = -0.9, @@ -467,13 +455,10 @@ biome_lib.register_on_generate({ }, "abstract_trunks.grow_moss_on_trunk" ) -end ----------------------------------------------------------------------------------------------- -- RooTS ----------------------------------------------------------------------------------------------- -if Roots == true then -- see settings.txt - abstract_trunks.grow_roots = function(pos) local right_here = {x=pos.x , y=pos.y , z=pos.z } local below = {x=pos.x , y=pos.y-1, z=pos.z } @@ -523,5 +508,3 @@ biome_lib.register_on_generate({ }, "abstract_trunks.grow_roots" ) - -end diff --git a/trunks/init.lua b/trunks/init.lua index 729ed13..4e08140 100644 --- a/trunks/init.lua +++ b/trunks/init.lua @@ -2,7 +2,8 @@ abstract_trunks = {} -dofile(minetest.get_modpath("trunks").."/trunks_settings.txt") dofile(minetest.get_modpath("trunks").."/generating.lua") dofile(minetest.get_modpath("trunks").."/nodes.lua") dofile(minetest.get_modpath("trunks").."/crafting.lua") + +abstract_trunks.loaded = true diff --git a/trunks/nodes.lua b/trunks/nodes.lua index f88df72..31bd817 100644 --- a/trunks/nodes.lua +++ b/trunks/nodes.lua @@ -239,98 +239,93 @@ minetest.register_node("trunks:twigs_roof_corner_2", { sounds = default.node_sound_wood_defaults(), }) -if Auto_Roof_Corner == true then +local roof = "trunks:twigs_roof" +local corner = "trunks:twigs_roof_corner" +local corner_2 = "trunks:twigs_roof_corner_2" - local roof = "trunks:twigs_roof" - local corner = "trunks:twigs_roof_corner" - local corner_2 = "trunks:twigs_roof_corner_2" +minetest.register_abm({ + nodenames = {roof}, + interval = 1, + chance = 1, + action = function(pos) - minetest.register_abm({ - nodenames = {roof}, - interval = 1, - chance = 1, - action = function(pos) + local node_east = minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }) + local node_west = minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }) + local node_north = minetest.get_node({x=pos.x, y=pos.y, z=pos.z+1}) + local node_south = minetest.get_node({x=pos.x, y=pos.y, z=pos.z-1}) + -- corner 1 + if ((node_west.name == roof and node_west.param2 == 0) + or (node_west.name == corner and node_west.param2 == 1)) + and ((node_north.name == roof and node_north.param2 == 3) + or (node_north.name == corner and node_north.param2 == 3)) + then + minetest.swap_node(pos, {name=corner, param2=0}) + end - local node_east = minetest.get_node({x=pos.x+1, y=pos.y, z=pos.z }) - local node_west = minetest.get_node({x=pos.x-1, y=pos.y, z=pos.z }) - local node_north = minetest.get_node({x=pos.x, y=pos.y, z=pos.z+1}) - local node_south = minetest.get_node({x=pos.x, y=pos.y, z=pos.z-1}) - -- corner 1 - if ((node_west.name == roof and node_west.param2 == 0) - or (node_west.name == corner and node_west.param2 == 1)) - and ((node_north.name == roof and node_north.param2 == 3) - or (node_north.name == corner and node_north.param2 == 3)) - then - minetest.swap_node(pos, {name=corner, param2=0}) - end + if ((node_north.name == roof and node_north.param2 == 1) + or (node_north.name == corner and node_north.param2 == 2)) + and ((node_east.name == roof and node_east.param2 == 0) + or (node_east.name == corner and node_east.param2 == 0)) + then + minetest.swap_node(pos, {name=corner, param2=1}) + end - if ((node_north.name == roof and node_north.param2 == 1) - or (node_north.name == corner and node_north.param2 == 2)) - and ((node_east.name == roof and node_east.param2 == 0) - or (node_east.name == corner and node_east.param2 == 0)) - then - minetest.swap_node(pos, {name=corner, param2=1}) - end + if ((node_east.name == roof and node_east.param2 == 2) + or (node_east.name == corner and node_east.param2 == 3)) + and ((node_south.name == roof and node_south.param2 == 1) + or (node_south.name == corner and node_south.param2 == 1)) + then + minetest.swap_node(pos, {name=corner, param2=2}) + end - if ((node_east.name == roof and node_east.param2 == 2) - or (node_east.name == corner and node_east.param2 == 3)) - and ((node_south.name == roof and node_south.param2 == 1) - or (node_south.name == corner and node_south.param2 == 1)) - then - minetest.swap_node(pos, {name=corner, param2=2}) - end + if ((node_south.name == roof and node_south.param2 == 3) + or (node_south.name == corner and node_south.param2 == 0)) + and ((node_west.name == roof and node_west.param2 == 2) + or (node_west.name == corner and node_west.param2 == 2)) + then + minetest.swap_node(pos, {name=corner, param2=3}) + end + -- corner 2 + if ((node_west.name == roof and node_west.param2 == 2) + or (node_west.name == corner_2 and node_west.param2 == 1)) + and ((node_north.name == roof and node_north.param2 == 1) + or (node_north.name == corner_2 and node_north.param2 == 3)) + then + minetest.swap_node(pos, {name=corner_2, param2=0}) + end - if ((node_south.name == roof and node_south.param2 == 3) - or (node_south.name == corner and node_south.param2 == 0)) - and ((node_west.name == roof and node_west.param2 == 2) - or (node_west.name == corner and node_west.param2 == 2)) - then - minetest.swap_node(pos, {name=corner, param2=3}) - end - -- corner 2 - if ((node_west.name == roof and node_west.param2 == 2) - or (node_west.name == corner_2 and node_west.param2 == 1)) - and ((node_north.name == roof and node_north.param2 == 1) - or (node_north.name == corner_2 and node_north.param2 == 3)) - then - minetest.swap_node(pos, {name=corner_2, param2=0}) - end + if ((node_north.name == roof and node_north.param2 == 3) + or (node_north.name == corner_2 and node_north.param2 == 2)) + and ((node_east.name == roof and node_east.param2 == 2) + or (node_east.name == corner_2 and node_east.param2 == 0)) + then + minetest.swap_node(pos, {name=corner_2, param2=1}) + end - if ((node_north.name == roof and node_north.param2 == 3) - or (node_north.name == corner_2 and node_north.param2 == 2)) - and ((node_east.name == roof and node_east.param2 == 2) - or (node_east.name == corner_2 and node_east.param2 == 0)) - then - minetest.swap_node(pos, {name=corner_2, param2=1}) - end + if ((node_east.name == roof and node_east.param2 == 0) + or (node_east.name == corner_2 and node_east.param2 == 3)) + and ((node_south.name == roof and node_south.param2 == 3) + or (node_south.name == corner_2 and node_south.param2 == 1)) + then + minetest.swap_node(pos, {name=corner_2, param2=2}) + end - if ((node_east.name == roof and node_east.param2 == 0) - or (node_east.name == corner_2 and node_east.param2 == 3)) - and ((node_south.name == roof and node_south.param2 == 3) - or (node_south.name == corner_2 and node_south.param2 == 1)) - then - minetest.swap_node(pos, {name=corner_2, param2=2}) - end + if ((node_south.name == roof and node_south.param2 == 1) + or (node_south.name == corner_2 and node_south.param2 == 0)) + and ((node_west.name == roof and node_west.param2 == 0) + or (node_west.name == corner_2 and node_west.param2 == 2)) + then + minetest.swap_node(pos, {name=corner_2, param2=3}) + end - if ((node_south.name == roof and node_south.param2 == 1) - or (node_south.name == corner_2 and node_south.param2 == 0)) - and ((node_west.name == roof and node_west.param2 == 0) - or (node_west.name == corner_2 and node_west.param2 == 2)) - then - minetest.swap_node(pos, {name=corner_2, param2=3}) - end - - end, - }) -end + end, +}) -- MM: The following stuff is just for testing purposes for now; no generating of roots. -- I'm not satisfied with this; they should be either bigger or a different drawtype. ----------------------------------------------------------------------------------------------- -- RooTS ----------------------------------------------------------------------------------------------- -if Roots == true then -- see settings.txt - local roots_cube = {-2/16, -1/2, -3/16, 2/16, 1/16, 1/2} local roots_sheet = {0, -1/2, -1/2, 0, 1/16, 1/2} @@ -401,7 +396,6 @@ for i in pairs(TRuNKS) do end end end -end minetest.register_alias("trunks:pine_trunkroot", "trunks:pine_treeroot") diff --git a/trunks/trunks_settings.txt b/trunks/trunks_settings.txt deleted file mode 100644 index 7fe8822..0000000 --- a/trunks/trunks_settings.txt +++ /dev/null @@ -1,70 +0,0 @@ --- Settings for generation of stuff (at map-generation time) - - - - - -Horizontal_Trunks = true - - - -Trunks_Max_Count = 320 -- absolute maximum number in an area of 80x80x80 nodes - - -Trunks_Rarity = 99 -- larger values make trunks more rare (100 means chance of 0 %) - - - - - -Big_Twigs = true -- twigs larger than one node -Twigs_on_ground = true - - - -Twigs_on_ground_Max_Count = 640 -- absolute maximum number in an area of 80x80x80 nodes - -Twigs_on_ground_Rarity = 66 -- larger values make twigs more rare (100 means chance of 0 %) - - - - - -Twigs_on_water = true - - - -Twigs_on_water_Max_Count = 320 -- absolute maximum number in an area of 80x80x80 nodes - - -Twigs_on_water_Rarity = 33 -- larger values make twigs more rare (100 means chance of 0 %) - - - - - -Moss_on_ground = true - - - -Moss_on_ground_Max_Count = 400 -- absolute maximum number in an area of 80x80x80 nodes - -Moss_on_ground_Rarity = 79 -- larger values makes moss more rare (100 means chance of 0 %) - - - - - -Moss_on_trunk = true - - - -Moss_on_trunk_Max_Count = 640 -- absolute maximum number in an area of 80x80x80 nodes - -Moss_on_trunk_Rarity = 24 -- larger values makes moss more rare (100 means chance of 0 %) - - -Auto_Roof_Corner = true -- behavior is similar (not the same!) to the one of minecraft stairs - - -Roots = true \ No newline at end of file From 69e272cd64f5b21636d3f7fe3ca5ee99fb6a3ded Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Sun, 23 Jul 2023 21:51:09 +0200 Subject: [PATCH 13/25] Fix naming incositencies (#54) * Fix naming incositencies * Update translations --- dryplants/locale/dryplants.de.tr | 4 ++-- dryplants/locale/dryplants.eo.tr | 4 ++-- dryplants/locale/dryplants.fr.tr | 4 ++-- dryplants/locale/template.txt | 4 ++-- dryplants/reed.lua | 8 ++++---- ferns/horsetail.lua | 4 ++-- ferns/locale/ferns.de.tr | 5 +++-- ferns/locale/ferns.eo.tr | 5 +++-- ferns/locale/ferns.fr.tr | 5 +++-- ferns/locale/template.txt | 5 +++-- youngtrees/locale/template.txt | 1 - youngtrees/locale/youngtrees.de.tr | 1 - youngtrees/locale/youngtrees.eo.tr | 1 - youngtrees/locale/youngtrees.fr.tr | 1 - 14 files changed, 26 insertions(+), 26 deletions(-) diff --git a/dryplants/locale/dryplants.de.tr b/dryplants/locale/dryplants.de.tr index 793a2d7..9558c58 100644 --- a/dryplants/locale/dryplants.de.tr +++ b/dryplants/locale/dryplants.de.tr @@ -7,12 +7,12 @@ Juncus=Binsen Wet Reed=Nasses Schilf Wet Reed Slab=Nasse Schilfplatte Wet Reed Roof=Nasses Schilfdach -Wet Reed Roof Corner=Nasser Schilfdachwinkel +Wet Reed Roof Corner 1=Nasser Schilfdachwinkel 1 Wet Reed Roof Corner 2=Nasser Schilfdachwinkel 2 Reed=Schilf Reed Slab=Schilfstufe Reed Roof=Schilfdach -Reed Roof Corner=Schilfdachwinkel +Reed Roof Corner 1=Schilfdachwinkel 1 Reed Roof Corner 2=Schilfdachwinkel Reedmace=Rohrkolben Reedmace, height: 1=Rohrkolben, Höhe: 1 diff --git a/dryplants/locale/dryplants.eo.tr b/dryplants/locale/dryplants.eo.tr index a9b36b9..afa0c0b 100644 --- a/dryplants/locale/dryplants.eo.tr +++ b/dryplants/locale/dryplants.eo.tr @@ -7,12 +7,12 @@ Juncus=Junko Wet Reed=Malseka Kano Wet Reed Slab=Slabo de Malseka Kano Wet Reed Roof=Tegmento de Malseka Kano -Wet Reed Roof Corner=Tegmentangulo de Malseka Kano +Wet Reed Roof Corner 1=Tegmentangulo 1 de Malseka Kano Wet Reed Roof Corner 2=Tegmentangulo 2 de Malseka Kano Reed=Kano Reed Slab=Slabo de Kano Reed Roof=Tegmento de Kano -Reed Roof Corner=Tegmentangulo de Kano +Reed Roof Corner 1=Tegmentangulo 1 de Kano Reed Roof Corner 2=Tegmentangulo 2 de Kano Reedmace=Tifeo Reedmace, height: 1=Tifeo, alteco: 1 diff --git a/dryplants/locale/dryplants.fr.tr b/dryplants/locale/dryplants.fr.tr index 4345799..b2a102f 100644 --- a/dryplants/locale/dryplants.fr.tr +++ b/dryplants/locale/dryplants.fr.tr @@ -7,12 +7,12 @@ Juncus=Joncs Wet Reed=Bloc de roseau humide Wet Reed Slab=Dalle en roseau humide Wet Reed Roof=Toit en roseau humide -Wet Reed Roof Corner=Angle de toit en roseau humide +Wet Reed Roof Corner 1=Angle de toit en roseau humide 1 Wet Reed Roof Corner 2=Angle de toit en roseau humide 2 Reed=Roseau Reed Slab=Dalle en roseau Reed Roof=Toit en roseau -Reed Roof Corner=Angle de toit en roseau +Reed Roof Corner 1=Angle de toit en roseau 1 Reed Roof Corner 2=Angle de toit en roseau 2 Reedmace=Roseau Reedmace, height: 1=Roseau, 1 de hauteur diff --git a/dryplants/locale/template.txt b/dryplants/locale/template.txt index a244774..a14ca62 100644 --- a/dryplants/locale/template.txt +++ b/dryplants/locale/template.txt @@ -7,12 +7,12 @@ Juncus= Wet Reed= Wet Reed Slab= Wet Reed Roof= -Wet Reed Roof Corner= +Wet Reed Roof Corner 1= Wet Reed Roof Corner 2= Reed= Reed Slab= Reed Roof= -Reed Roof Corner= +Reed Roof Corner 1= Reed Roof Corner 2= Reedmace= Reedmace, height: 1= diff --git a/dryplants/reed.lua b/dryplants/reed.lua index 1b7f0b3..1d3bbc7 100644 --- a/dryplants/reed.lua +++ b/dryplants/reed.lua @@ -168,10 +168,10 @@ for i in pairs(CoRNeR) do end ----------------------------------------------------------------------------------------------- --- Wet Reed Roof Corner +-- Wet Reed Roof Corner 1 ----------------------------------------------------------------------------------------------- minetest.register_node("dryplants:wetreed_roof_corner", { - description = S("Wet Reed Roof Corner"), + description = S("Wet Reed Roof Corner 1"), drawtype = "nodebox", paramtype = "light", paramtype2 = "facedir", @@ -316,10 +316,10 @@ minetest.register_node("dryplants:reed_roof", { }) ----------------------------------------------------------------------------------------------- --- Reed Roof Corner +-- Reed Roof Corner 1 ----------------------------------------------------------------------------------------------- minetest.register_node("dryplants:reed_roof_corner", { - description = S("Reed Roof Corner"), + description = S("Reed Roof Corner 1"), drawtype = "nodebox", paramtype = "light", paramtype2 = "facedir", diff --git a/ferns/horsetail.lua b/ferns/horsetail.lua index f190b8b..21ef862 100644 --- a/ferns/horsetail.lua +++ b/ferns/horsetail.lua @@ -34,13 +34,13 @@ local function create_nodes() local node_drop = "ferns:horsetail_04" if i == 1 then - node_desc = S("Young Horsetail (Equisetum)") + node_desc = S("Young Horsetail (Equisetum) @1", 1) node_on_use = minetest.item_eat(1) -- young ones edible https://en.wikipedia.org/wiki/Equisetum node_drop = node_name elseif i == 4 then node_desc = S("Horsetail (Equisetum)") else - node_desc = S("Horsetail (Equisetum)").." ".. string.format("%02d", i) + node_desc = S("Horsetail (Equisetum) @1", i) end node_names[i] = node_name diff --git a/ferns/locale/ferns.de.tr b/ferns/locale/ferns.de.tr index a9582d7..ed94945 100644 --- a/ferns/locale/ferns.de.tr +++ b/ferns/locale/ferns.de.tr @@ -8,8 +8,9 @@ Giant Tree Fern Leaves=Riesige Baumfarnblätter Giant Tree Fern Leave End=Riesiges Baumfarnblattende Giant Fern Trunk=Riesiger Baumfarnstamm Giant Tree Fern Sapling=Riesiger Baumfarnsetzling -Young Horsetail (Equisetum)=Junger Schachtelhalm (Equisetum) +Tree Fern Crown (Dicksonia)=Baumfarnkrone (Dicksonia) +Young Horsetail (Equisetum) @1=Junger Schachtelhalm (Equisetum) @1 Horsetail (Equisetum)=Schachtelhalm (Equisetum) +Horsetail (Equisetum) @1= Schachtelhalm (Equisetum) @1 Fern Trunk (Dicksonia)=Farnstamm (Dicksonia) Tree Fern Sapling (Dicksonia)=Baumfarnsetzling (Dicksonia) -Tree Fern Crown (Dicksonia)=Baumfarnkrone (Dicksonia) diff --git a/ferns/locale/ferns.eo.tr b/ferns/locale/ferns.eo.tr index ad0bde3..11d0893 100644 --- a/ferns/locale/ferns.eo.tr +++ b/ferns/locale/ferns.eo.tr @@ -8,8 +8,9 @@ Giant Tree Fern Leaves=Folioj de Giganta Arba Filiko Giant Tree Fern Leave End=Folifino de Giganta Arba Filiko Giant Fern Trunk=Trunko de Giganta Arba Filiko Giant Tree Fern Sapling=Arbido de Giganta Arba Filiko -Young Horsetail (Equisetum)=Juna Ekvizeto (Equisetum) +Tree Fern Crown (Dicksonia)=Krono de Arba Filiko +Young Horsetail (Equisetum) @1=Juna Ekvizeto (Equisetum) @1 Horsetail (Equisetum)=Ekvizeto (Equisetum) +Horsetail (Equisetum) @1=Ekvizeto (Equisetum) @1 Fern Trunk (Dicksonia)=Trunko de Arba Filiko (Dicksonia) Tree Fern Sapling (Dicksonia)=Arbido de Arba Filiko (Dicksonia) -Tree Fern Crown (Dicksonia)=Krono de Arba Filiko diff --git a/ferns/locale/ferns.fr.tr b/ferns/locale/ferns.fr.tr index c893605..f7364f5 100644 --- a/ferns/locale/ferns.fr.tr +++ b/ferns/locale/ferns.fr.tr @@ -8,8 +8,9 @@ Giant Tree Fern Leaves=Feuilles de fougère géante Giant Tree Fern Leave End=Feuilles de fougère géante (extrémité) Giant Fern Trunk=Tronc de fougère géante Giant Tree Fern Sapling=Pousse de fougère géante -Young Horsetail (Equisetum)=Pousse de prêle (Equisetum) +Tree Fern Crown (Dicksonia)=Fougère en couronne (Dicksonia) +Young Horsetail (Equisetum) @1=Pousse de prêle (Equisetum) @1 Horsetail (Equisetum)=Prêle (Equisetum) +Horsetail (Equisetum) @1=Prêle (Equisetum) @1 Fern Trunk (Dicksonia)=Tronc de fougère en couronne (Dicksonia) Tree Fern Sapling (Dicksonia)=Pousse de fougère en couronne (Dicksonia) -Tree Fern Crown (Dicksonia)=Fougère en couronne (Dicksonia) diff --git a/ferns/locale/template.txt b/ferns/locale/template.txt index b438c8c..8000257 100644 --- a/ferns/locale/template.txt +++ b/ferns/locale/template.txt @@ -8,8 +8,9 @@ Giant Tree Fern Leaves= Giant Tree Fern Leave End= Giant Fern Trunk= Giant Tree Fern Sapling= -Young Horsetail (Equisetum)= +Tree Fern Crown (Dicksonia)= +Young Horsetail (Equisetum) @1= Horsetail (Equisetum)= +Horsetail (Equisetum) @1= Fern Trunk (Dicksonia)= Tree Fern Sapling (Dicksonia)= -Tree Fern Crown (Dicksonia)= diff --git a/youngtrees/locale/template.txt b/youngtrees/locale/template.txt index 33048ea..a7ebcaa 100644 --- a/youngtrees/locale/template.txt +++ b/youngtrees/locale/template.txt @@ -1,6 +1,5 @@ # textdomain: youngtrees Young Bamboo Tree= -Young Tree 2 (middle)= Young Tree (top)= Young Tree (middle)= Young Tree (bottom)= diff --git a/youngtrees/locale/youngtrees.de.tr b/youngtrees/locale/youngtrees.de.tr index 0024f8e..8ada50a 100644 --- a/youngtrees/locale/youngtrees.de.tr +++ b/youngtrees/locale/youngtrees.de.tr @@ -1,6 +1,5 @@ # textdomain: youngtrees Young Bamboo Tree=Junger Bambus -Young Tree 2 (middle)=Strauch 2 (Mitte) Young Tree (top)=Strauch (Spitze) Young Tree (middle)=Strauch (Mitte) Young Tree (bottom)=Strauch (Ansatz) diff --git a/youngtrees/locale/youngtrees.eo.tr b/youngtrees/locale/youngtrees.eo.tr index 3aeca86..365f0c7 100644 --- a/youngtrees/locale/youngtrees.eo.tr +++ b/youngtrees/locale/youngtrees.eo.tr @@ -1,6 +1,5 @@ # textdomain: youngtrees Young Bamboo Tree=Juna Bambuarbo -Young Tree 2 (middle)=Juna Arbo 2 (mezo) Young Tree (top)=Juna Arbo (supro) Young Tree (middle)=Juna Arbo (mezo) Young Tree (bottom)=Juna Arbo (malsupro) diff --git a/youngtrees/locale/youngtrees.fr.tr b/youngtrees/locale/youngtrees.fr.tr index 19d9533..1c9f437 100644 --- a/youngtrees/locale/youngtrees.fr.tr +++ b/youngtrees/locale/youngtrees.fr.tr @@ -1,6 +1,5 @@ # textdomain: youngtrees Young Bamboo Tree=Bambou jeune -Young Tree 2 (middle)=Arbuste 2 (milieu) Young Tree (top)=Arbuste (haut) Young Tree (middle)=Arbuste (milieu) Young Tree (bottom)=Arbuste (bas) From 9e771e2988a3ba39df9014e6c2a44077cfefc5df Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Mon, 28 Aug 2023 11:34:00 +0200 Subject: [PATCH 14/25] Add attached_node group to poisonivy nodes (#56) --- poisonivy/init.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/poisonivy/init.lua b/poisonivy/init.lua index a1d33b3..cdc238e 100644 --- a/poisonivy/init.lua +++ b/poisonivy/init.lua @@ -25,7 +25,7 @@ minetest.register_node('poisonivy:seedling', { sunlight_propagates = true, paramtype = 'light', walkable = false, - groups = { snappy = 3, poisonivy=1, flora_block=1 }, + groups = { snappy = 3, poisonivy=1, flora_block=1, attached_node=1 }, sounds = default.node_sound_leaves_defaults(), buildable_to = true, }) @@ -40,7 +40,7 @@ minetest.register_node('poisonivy:sproutling', { sunlight_propagates = true, paramtype = 'light', walkable = false, - groups = { snappy = 3, poisonivy=1, flora_block=1 }, + groups = { snappy = 3, poisonivy=1, flora_block=1, attached_node=1 }, sounds = default.node_sound_leaves_defaults(), buildable_to = true, }) @@ -55,7 +55,7 @@ minetest.register_node('poisonivy:climbing', { paramtype = 'light', paramtype2 = 'wallmounted', walkable = false, - groups = { snappy = 3, poisonivy=1, flora_block=1 }, + groups = { snappy = 3, poisonivy=1, flora_block=1, attached_node=1 }, sounds = default.node_sound_leaves_defaults(), selection_box = { type = "wallmounted", From 6a3c47157f44e9f6695b8780d70be99d53e3d1d7 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Wed, 30 Aug 2023 23:30:10 +0200 Subject: [PATCH 15/25] Add protection check when digging vines (#58) --- vines/init.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/vines/init.lua b/vines/init.lua index 1f4f0b4..2a52632 100644 --- a/vines/init.lua +++ b/vines/init.lua @@ -37,6 +37,9 @@ end -- FUNCTIONS local function on_dig(pos, node, player) + if not player or minetest.is_protected(pos, player:get_player_name()) then + return + end local vine_name_end = node.name:gsub("_middle", "_end") local drop_item = "vines:vines" if enable_vines == false then From 72572bb5c816ad1b7734544960b171d8edf29b2d Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Sat, 23 Sep 2023 19:18:18 +0200 Subject: [PATCH 16/25] Use proper creative mode check (#59) --- .gitignore | 1 - cavestuff/nodes.lua | 2 +- dryplants/juncus.lua | 2 +- dryplants/reedmace.lua | 2 +- modpack.txt | 0 trunks/nodes.lua | 2 +- 6 files changed, 4 insertions(+), 5 deletions(-) delete mode 100644 .gitignore delete mode 100644 modpack.txt diff --git a/.gitignore b/.gitignore deleted file mode 100644 index b25c15b..0000000 --- a/.gitignore +++ /dev/null @@ -1 +0,0 @@ -*~ diff --git a/cavestuff/nodes.lua b/cavestuff/nodes.lua index a5211d7..e3e2df0 100644 --- a/cavestuff/nodes.lua +++ b/cavestuff/nodes.lua @@ -112,7 +112,7 @@ minetest.register_node("cavestuff:stalactite_1",{ name = "cavestuff:stalactite_"..math.random(1,3), param2 = minetest.dir_to_wallmounted(vector.multiply(dir, -1)) }) - if not minetest.setting_getbool("creative_mode") then + if not minetest.is_creative_enabled(playername) then itemstack:take_item() end end diff --git a/dryplants/juncus.lua b/dryplants/juncus.lua index 8c36092..a2f0166 100644 --- a/dryplants/juncus.lua +++ b/dryplants/juncus.lua @@ -64,7 +64,7 @@ minetest.register_node("dryplants:juncus", { else minetest.swap_node(right_here, {name="dryplants:juncus"}) end - if not minetest.setting_getbool("creative_mode") then + if not minetest.is_creative_enabled(playername) then itemstack:take_item() end return itemstack diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index 6d5ecda..e9547be 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -318,7 +318,7 @@ minetest.register_entity("dryplants:reedmace_water_entity",{ collisionbox = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3}, on_punch = function(self, puncher) if puncher:is_player() and puncher:get_inventory() then - if not minetest.setting_getbool("creative_mode") then + if not minetest.is_creative_enabled(puncher:get_player_name()) then puncher:get_inventory():add_item("main", "dryplants:reedmace_sapling") end self.object:remove() diff --git a/modpack.txt b/modpack.txt deleted file mode 100644 index e69de29..0000000 diff --git a/trunks/nodes.lua b/trunks/nodes.lua index 31bd817..909a3c1 100644 --- a/trunks/nodes.lua +++ b/trunks/nodes.lua @@ -54,7 +54,7 @@ for i in pairs(NoDe) do local direction = minetest.dir_to_facedir(placer:get_look_dir()) if minetest.get_node(pt.above).name=="air" then minetest.swap_node(pt.above, {name="trunks:twig_"..math.random(1,4), param2=direction}) - if not minetest.setting_getbool("creative_mode") then + if not minetest.is_creative_enabled(playername) then itemstack:take_item() end return itemstack From ab9a91259878fccdebd4392fc70acce8e33b78de Mon Sep 17 00:00:00 2001 From: OgelGames Date: Sun, 24 Sep 2023 16:55:42 +1000 Subject: [PATCH 17/25] bump min minetest version to 5.3.0 for `is_creative_enabled` --- modpack.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modpack.conf b/modpack.conf index c06e07d..7469b3d 100644 --- a/modpack.conf +++ b/modpack.conf @@ -1 +1 @@ -min_minetest_version = 5.2.0 +min_minetest_version = 5.3.0 From 46608a7fb9066b72b6bc00b22a775d68d9ca7869 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Tue, 24 Oct 2023 01:33:59 +0200 Subject: [PATCH 18/25] Remove biome_lib dep from bushes (#61) * Remove biome_lib dep from bushes * Indent using tabs * Add configurable spawn rarity --- .luacheckrc | 2 +- bushes/init.lua | 208 ++++++++++++++++++++++++---------------- bushes/mod.conf | 3 +- bushes/settingtypes.txt | 20 +--- 4 files changed, 135 insertions(+), 98 deletions(-) diff --git a/.luacheckrc b/.luacheckrc index 549462d..1a1dfc6 100644 --- a/.luacheckrc +++ b/.luacheckrc @@ -6,7 +6,7 @@ exclude_files = {".luacheckrc"} globals = { "biome_lib", "abstract_dryplants", - "bushes_classic", "abstract_trunks", + "bushes_classic", } read_globals = { diff --git a/bushes/init.lua b/bushes/init.lua index f541259..9b5c553 100644 --- a/bushes/init.lua +++ b/bushes/init.lua @@ -8,16 +8,9 @@ -- support for i18n local S = minetest.get_translator("bushes") -abstract_bushes = {} - -local bushes_bush_rarity = tonumber(minetest.settings:get("bushes_bush_rarity")) or 99.9 -local bushes_bush_rarity_fertility = tonumber(minetest.settings:get("bushes_bush_rarity_fertility")) or 1.5 -local bushes_bush_fertility = tonumber(minetest.settings:get("bushes_bush_fertility")) or -1 - -local bushes_youngtrees_rarity = tonumber(minetest.settings:get("bushes_youngtrees_rarity")) or 100 -local bushes_youngtrees_rarity_fertility = tonumber(minetest.settings:get("bushes_youngtrees_rarity_fertility")) or 0.6 -local bushes_youngtrees_fertility = tonumber(minetest.settings:get("bushes_youngtrees_fertility")) or -0.5 +local bush_rarity = minetest.settings:get("bushes.bush_rarity") or 0.008 +local youngtree_rarity = minetest.settings:get("youngtree.bush_rarity") or 0.006 minetest.register_node("bushes:youngtree2_bottom", { description = S("Young Tree 2 (bottom)"), @@ -142,44 +135,12 @@ for i in pairs(BushLeafNode) do }) end -abstract_bushes.grow_bush = function(pos) - local leaf_type = math.random(1,2) - local bush_side_height = math.random(0,1) - local chance_of_bush_node_right = math.random(1,10) - if chance_of_bush_node_right> 5 then - local right_pos = {x=pos.x+1, y=pos.y+bush_side_height, z=pos.z} - abstract_bushes.grow_bush_node(right_pos,3,leaf_type) - end - local chance_of_bush_node_left = math.random(1,10) - if chance_of_bush_node_left> 5 then - bush_side_height = math.random(0,1) - local left_pos = {x=pos.x-1, y=pos.y+bush_side_height, z=pos.z} - abstract_bushes.grow_bush_node(left_pos,1,leaf_type) - end - local chance_of_bush_node_front = math.random(1,10) - if chance_of_bush_node_front> 5 then - bush_side_height = math.random(0,1) - local front_pos = {x=pos.x, y=pos.y+bush_side_height, z=pos.z+1} - abstract_bushes.grow_bush_node(front_pos,2,leaf_type) - end - local chance_of_bush_node_back = math.random(1,10) - if chance_of_bush_node_back> 5 then - bush_side_height = math.random(0,1) - local back_pos = {x=pos.x, y=pos.y+bush_side_height, z=pos.z-1} - abstract_bushes.grow_bush_node(back_pos,0,leaf_type) - end - -abstract_bushes.grow_bush_node(pos,5,leaf_type) -end - - -abstract_bushes.grow_bush_node = function(pos,dir, leaf_type) +local function grow_bush_node(pos, dir, leaf_type) local right_here = {x=pos.x, y=pos.y+1, z=pos.z} local above_right_here = {x=pos.x, y=pos.y+2, z=pos.z} local bush_branch_type = 2 - -- MM: I'm not sure if it's slower now than before... if dir ~= 5 and leaf_type == 1 then bush_branch_type = 2 end @@ -195,53 +156,108 @@ abstract_bushes.grow_bush_node = function(pos,dir, leaf_type) dir = 1 end - if minetest.get_node(right_here).name == "air" -- instead of check_air = true, - or minetest.get_node(right_here).name == "default:junglegrass" then + local nodename = minetest.get_node(right_here).name + if nodename == "air" or nodename == "default:junglegrass" then -- instead of check_air = true, minetest.swap_node(right_here, {name="bushes:bushbranches"..bush_branch_type , param2=dir}) - --minetest.chat_send_all("leaf_type: (" .. leaf_type .. ")") minetest.swap_node(above_right_here, {name="bushes:BushLeaves"..leaf_type}) + local chance_of_high_leaves = math.random(1,10) - if chance_of_high_leaves> 5 then + if chance_of_high_leaves > 5 then local two_above_right_here = {x=pos.x, y=pos.y+3, z=pos.z} - --minetest.chat_send_all("leaf_type: (" .. leaf_type .. ")") minetest.swap_node(two_above_right_here, {name="bushes:BushLeaves"..leaf_type}) end end end +local function grow_bush(pos) + -- replace possible grass nodes + minetest.swap_node({x=pos.x, y=pos.y+1, z=pos.z}, {name="air"}) -biome_lib.register_on_generate({ - surface = { - "default:dirt_with_grass", - "stoneage:grass_with_silex", - "sumpf:peat", - "sumpf:sumpf" - }, - rarity = bushes_bush_rarity, - rarity_fertility = bushes_bush_rarity_fertility, - plantlife_limit = bushes_bush_fertility, - min_elevation = 1, -- above sea level - }, - abstract_bushes.grow_bush -) + local leaf_type = math.random(1,2) + local bush_side_height = math.random(0,1) -abstract_bushes.grow_youngtree2 = function(pos) - local height = math.random(4,5) - abstract_bushes.grow_youngtree_node2(pos,height) + local chance_of_bush_node_right = math.random(1,10) + if chance_of_bush_node_right > 5 then + local right_pos = {x=pos.x+1, y=pos.y+bush_side_height, z=pos.z} + grow_bush_node(right_pos,3,leaf_type) + end + + local chance_of_bush_node_left = math.random(1,10) + if chance_of_bush_node_left > 5 then + local left_pos = {x=pos.x-1, y=pos.y+bush_side_height, z=pos.z} + grow_bush_node(left_pos,1,leaf_type) + end + + local chance_of_bush_node_front = math.random(1,10) + if chance_of_bush_node_front > 5 then + local front_pos = {x=pos.x, y=pos.y+bush_side_height, z=pos.z+1} + grow_bush_node(front_pos,2,leaf_type) + end + + local chance_of_bush_node_back = math.random(1,10) + if chance_of_bush_node_back > 5 then + local back_pos = {x=pos.x, y=pos.y+bush_side_height, z=pos.z-1} + grow_bush_node(back_pos,0,leaf_type) + end + + grow_bush_node(pos,5,leaf_type) end +minetest.register_decoration({ + name = "bushes:bush", + decoration = { + "air" + }, + fill_ratio = bush_rarity, + y_min = 1, + y_max = 40, + place_on = { + "default:dirt_with_grass", + "stoneage:grass_with_silex", + "sumpf:peat", + "sumpf:sumpf" + }, + deco_type = "simple", + flags = "all_floors", +}) -abstract_bushes.grow_youngtree_node2 = function(pos, height) +--[[ + this is purposefully wrapped in a on mods loaded callback to that it gets the proper ids + if other mods clear the registered decorations +]] +local did +minetest.register_on_mods_loaded(function() + did = minetest.get_decoration_id("bushes:bush") + minetest.set_gen_notify("decoration", {did}) +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations = g["decoration#" .. did] or {} + for _, pos in pairs(deco_locations) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + grow_bush(pos) + end +end) + +local function grow_youngtree_node2(pos, height) local right_here = {x=pos.x, y=pos.y+1, z=pos.z} local above_right_here = {x=pos.x, y=pos.y+2, z=pos.z} local two_above_right_here = {x=pos.x, y=pos.y+3, z=pos.z} local three_above_right_here = {x=pos.x, y=pos.y+4, z=pos.z} - if minetest.get_node(right_here).name == "air" -- instead of check_air = true, - or minetest.get_node(right_here).name == "default:junglegrass" then + local nodename = minetest.get_node(right_here).name + if nodename == "air" or nodename == "default:junglegrass" then -- instead of check_air = true, if height == 4 then local two_above_right_here_south = {x=pos.x, y=pos.y+3, z=pos.z-1} local three_above_right_here_south = {x=pos.x, y=pos.y+4, z=pos.z-1} + minetest.swap_node(right_here, {name="bushes:youngtree2_bottom"}) minetest.swap_node(above_right_here, {name="bushes:youngtree2_bottom"}) minetest.swap_node(two_above_right_here, {name="bushes:bushbranches2" , param2=2}) @@ -252,18 +268,50 @@ abstract_bushes.grow_youngtree_node2 = function(pos, height) end end +local function grow_youngtree2(pos) + local height = math.random(4,5) + grow_youngtree_node2(pos,height) +end -biome_lib.register_on_generate({ - surface = { - "default:dirt_with_grass", - "stoneage:grass_with_silex", - "sumpf:peat", - "sumpf:sumpf" - }, - rarity = bushes_youngtrees_rarity, - rarity_fertility = bushes_youngtrees_rarity_fertility, - plantlife_limit = bushes_youngtrees_fertility, - min_elevation = 1, -- above sea level +minetest.register_decoration({ + name = "bushes:youngtree", + decoration = { + "air" }, - abstract_bushes.grow_youngtree2 -) + fill_ratio = youngtree_rarity, + y_min = 1, + y_max = 40, + place_on = { + "default:dirt_with_grass", + "stoneage:grass_with_silex", + "sumpf:peat", + "sumpf:sumpf" + }, + deco_type = "simple", + flags = "all_floors", +}) + +--[[ + this is purposefully wrapped in a on mods loaded callback to that it gets the proper ids + if other mods clear the registered decorations +]] +local did2 +minetest.register_on_mods_loaded(function() + did2 = minetest.get_decoration_id("bushes:youngtree") + minetest.set_gen_notify("decoration", {did2}) +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations = g["decoration#" .. did2] or {} + for _, pos in pairs(deco_locations) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + grow_youngtree2(pos) + end +end) \ No newline at end of file diff --git a/bushes/mod.conf b/bushes/mod.conf index 0a4f665..822e050 100644 --- a/bushes/mod.conf +++ b/bushes/mod.conf @@ -1,3 +1,4 @@ name = bushes -depends = default, biome_lib +title = Bushes +depends = default optional_depends = stoneage, sumpf diff --git a/bushes/settingtypes.txt b/bushes/settingtypes.txt index 77c5d57..34b2cb0 100644 --- a/bushes/settingtypes.txt +++ b/bushes/settingtypes.txt @@ -1,17 +1,5 @@ -#Bush rarity % -bushes_bush_rarity (Bush rarity %) float 99.9 0 100 +# Bush rarity (higher number -> higher probability) +bushes.bush_rarity (Bush rarity) float 0.008 0.0001 1 -#How much the rarity is reduced by fertility % -bushes_bush_rarity_fertility (Bush rarity fertility reduction %) float 1.5 0 100 - -#Bush minimum fertility (-1 to +1) -bushes_bush_fertility (Bush minimum fertility) float -0.7 -1 1 - -#Youngtree (from bushes mod) rarity % -bushes_youngtrees_rarity (Youngtree bush rarity %) float 100 0 100 - -#How much the rarity is reduced by fertility % -bushes_youngtrees_rarity_fertility (Youngtree bush rarity fertility reduction %) float 0.6 0 100 - -#Youngtree (from bushes mod) minimum fertility (-1 to +1) -bushes_youngtrees_fertility (Youngtree bush minimum fertility) float -0.5 -1 1 +# Youngtree rarity (higher number -> higher probability) +bushes.youngtree_rarity (Youngtree rarity) float 0.006 0.0001 1 From 3fce92a9f5aa23335e3bbbec40693da6434fbec8 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Tue, 24 Oct 2023 12:52:42 +0200 Subject: [PATCH 19/25] Re-add simple spawn settings for some plants (#62) * Red-add simple spawn settings for some plants * Add pl_ --- molehills/init.lua | 4 +++- molehills/settingtypes.txt | 2 ++ pl_sunflowers/init.lua | 4 +++- pl_sunflowers/settingtypes.txt | 7 ++----- youngtrees/init.lua | 4 +++- youngtrees/settingtypes.txt | 2 ++ 6 files changed, 15 insertions(+), 8 deletions(-) create mode 100644 molehills/settingtypes.txt create mode 100644 youngtrees/settingtypes.txt diff --git a/molehills/init.lua b/molehills/init.lua index c6f7824..2c35376 100644 --- a/molehills/init.lua +++ b/molehills/init.lua @@ -4,6 +4,8 @@ -- support for i18n local S = minetest.get_translator("molehills") +local molehill_rarity = minetest.settings:get("molehills.molehill_rarity") or 0.002 + -- Node local mh_cbox = { type = "fixed", @@ -38,7 +40,7 @@ minetest.register_decoration({ decoration = { "molehills:molehill" }, - fill_ratio = 0.002, + fill_ratio = molehill_rarity, y_min = 1, y_max = 40, place_on = { diff --git a/molehills/settingtypes.txt b/molehills/settingtypes.txt new file mode 100644 index 0000000..4a95084 --- /dev/null +++ b/molehills/settingtypes.txt @@ -0,0 +1,2 @@ +# Molehill rarity (higher number -> higher probability) +molehills.molehill_rarity (Molehill rarity) float 0.002 0.0001 1 diff --git a/pl_sunflowers/init.lua b/pl_sunflowers/init.lua index a801ff8..738cab6 100644 --- a/pl_sunflowers/init.lua +++ b/pl_sunflowers/init.lua @@ -1,6 +1,8 @@ -- support for i18n local S = minetest.get_translator("pl_sunflowers") +local sunflower_rarity = minetest.settings:get("pl_sunflowers.sunflower_rarity") or 0.005 + local box = { type="fixed", fixed = { { -0.2, -0.5, -0.2, 0.2, 0.5, 0.2 } }, @@ -40,7 +42,7 @@ minetest.register_decoration({ decoration = { "flowers:sunflower" }, - fill_ratio = 0.005, + fill_ratio = sunflower_rarity, y_min = 1, y_max = 40, param2 = 0, diff --git a/pl_sunflowers/settingtypes.txt b/pl_sunflowers/settingtypes.txt index 67af9e4..0de2098 100644 --- a/pl_sunflowers/settingtypes.txt +++ b/pl_sunflowers/settingtypes.txt @@ -1,5 +1,2 @@ -#Sunflowers maximum count -pl_sunflowers_max_count (Sunflowers maximum count) int 10 1 1000 - -#Sunflowers rarity -pl_sunflowers_rarity (Sunflowers rarity) int 25 0 100 +# Sunflower rarity (higher number -> higher probability) +pl_sunflowers.sunflower_rarity (Sunflower rarity) float 0.005 0.0001 1 diff --git a/youngtrees/init.lua b/youngtrees/init.lua index 91c1bfe..b69da5d 100644 --- a/youngtrees/init.lua +++ b/youngtrees/init.lua @@ -1,6 +1,8 @@ -- support for i18n local S = minetest.get_translator("youngtrees") +local youngtree_rarity = minetest.settings:get("youngtrees.youngtree_rarity") or 0.0005 + minetest.register_node("youngtrees:bamboo", { description = S("Young Bamboo Tree"), drawtype="nodebox", @@ -105,7 +107,7 @@ minetest.register_decoration({ decoration = { "youngtrees:youngtree_bottom" }, - fill_ratio = 0.0005, + fill_ratio = youngtree_rarity, y_min = 1, y_max = 40, param2 = 0, diff --git a/youngtrees/settingtypes.txt b/youngtrees/settingtypes.txt new file mode 100644 index 0000000..de07b5b --- /dev/null +++ b/youngtrees/settingtypes.txt @@ -0,0 +1,2 @@ +# Youngtree rarity (higher number -> higher probability) +youngtrees.youngtree_rarity (Youngtree rarity) float 0.0005 0.0001 1 From fbd4aaf0349d93dd3e9aa98b7d472a6b51413ec5 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Thu, 26 Oct 2023 17:53:09 +0200 Subject: [PATCH 20/25] Remove biome_lib dep from dryplants (#63) --- .luacheckrc | 2 +- dryplants/init.lua | 12 --- dryplants/juncus.lua | 113 +++++++++++--------- dryplants/meadowvariation.lua | 33 ++---- dryplants/mod.conf | 2 +- dryplants/moregrass.lua | 42 +++----- dryplants/reedmace.lua | 190 +++++++++++++++++++--------------- 7 files changed, 201 insertions(+), 193 deletions(-) diff --git a/.luacheckrc b/.luacheckrc index 1a1dfc6..a8b6e7c 100644 --- a/.luacheckrc +++ b/.luacheckrc @@ -5,7 +5,7 @@ max_line_length = 185 exclude_files = {".luacheckrc"} globals = { - "biome_lib", "abstract_dryplants", + "biome_lib", "bushes_classic", } diff --git a/dryplants/init.lua b/dryplants/init.lua index 11235e4..5b808c0 100644 --- a/dryplants/init.lua +++ b/dryplants/init.lua @@ -1,13 +1,3 @@ --- by Mossmanikin --- textures & ideas partly by Neuromancer - --- Contains code from: default, farming --- Looked at code from: darkage, sickle, stairs --- Dependencies: default, farming, biome_lib --- Supports: ------------------------------------------------------------------------------------------------ -abstract_dryplants = {} - -- support for i18n local S = minetest.get_translator("dryplants") @@ -191,5 +181,3 @@ minetest.register_abm({ end end, }) - -abstract_dryplants.loaded = true diff --git a/dryplants/juncus.lua b/dryplants/juncus.lua index a2f0166..4a73861 100644 --- a/dryplants/juncus.lua +++ b/dryplants/juncus.lua @@ -1,21 +1,12 @@ ------------------------------------------------------------------------------------------------ --- Grasses - Juncus 0.0.5 ------------------------------------------------------------------------------------------------ --- by Mossmanikin --- textures & ideas partly by Neuromancer - --- Contains code from: biome_lib --- Looked at code from: default ------------------------------------------------------------------------------------------------ - -- support for i18n local S = minetest.get_translator("dryplants") -abstract_dryplants.grow_juncus = function(pos) +local function grow_juncus(pos) local juncus_type = math.random(2,3) local right_here = {x=pos.x, y=pos.y+1, z=pos.z} - if minetest.get_node(right_here).name == "air" -- instead of check_air = true, - or minetest.get_node(right_here).name == "default:junglegrass" then + + local nodename = minetest.get_node(right_here).name + if nodename == "air" or nodename == "default:junglegrass" then if juncus_type == 2 then minetest.swap_node(right_here, {name="dryplants:juncus_02"}) else @@ -70,6 +61,7 @@ minetest.register_node("dryplants:juncus", { return itemstack end, }) + minetest.register_node("dryplants:juncus_02", { description = S("Juncus"), drawtype = "plantlike", @@ -96,44 +88,69 @@ minetest.register_node("dryplants:juncus_02", { -- GENERATE SMALL JUNCUS ----------------------------------------------------------------------------------------------- -- near water or swamp -biome_lib.register_on_generate({ - surface = { +minetest.register_decoration({ + name = "dryplants:juncus_water", + decoration = {"air"}, + fill_ratio = 0.16, + y_min = 1, + y_max = 40, + place_on = { "default:dirt_with_grass", - --"default:desert_sand", - --"default:sand", "stoneage:grass_with_silex", "sumpf:peat", "sumpf:sumpf" }, - max_count = 70, - rarity = 101 - 75, - min_elevation = 1, -- above sea level - near_nodes = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_juncus -) --- at dunes/beach -biome_lib.register_on_generate({ - surface = { - --"default:dirt_with_grass", - --"default:desert_sand", - "default:sand", - --"stoneage:grass_with_silex", - --"sumpf:peat", - --"sumpf:sumpf" + deco_type = "simple", + flags = "all_floors", + spawn_by = { + "default:water_source", + "sumpf:dirtywater_source", + "sumpf:sumpf" }, - max_count = 70, - rarity = 101 - 75, - min_elevation = 1, -- above sea level - near_nodes = {"default:dirt_with_grass"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_juncus -) + check_offset = -1, + num_spawn_by = 1 +}) + +-- at dunes/beach +minetest.register_decoration({ + name = "dryplants:juncus_beach", + decoration = {"air"}, + fill_ratio = 0.08, + y_min = 1, + y_max = 40, + place_on = { + "default:sand", + }, + deco_type = "simple", + flags = "all_floors", + spawn_by = {"default:dirt_with_grass"}, + check_offset = -1, + num_spawn_by = 1 +}) + +local did, did2 +minetest.register_on_mods_loaded(function() + did = minetest.get_decoration_id("dryplants:juncus_water") + did2 = minetest.get_decoration_id("dryplants:juncus_beach") + minetest.set_gen_notify("decoration", {did, did2}) +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations_1 = g["decoration#" .. did] or {} + local deco_locations_2 = g["decoration#" .. did2] or {} + + for _, pos in pairs(deco_locations_1) do + locations[#locations+1] = pos + end + for _, pos in pairs(deco_locations_2) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + grow_juncus(pos) + end +end) \ No newline at end of file diff --git a/dryplants/meadowvariation.lua b/dryplants/meadowvariation.lua index d11d7da..c9ebf1c 100644 --- a/dryplants/meadowvariation.lua +++ b/dryplants/meadowvariation.lua @@ -1,25 +1,12 @@ ------------------------------------------------------------------------------------------------ --- Grasses - Meadow Variation 0.0.1 ------------------------------------------------------------------------------------------------ --- by Mossmanikin - --- Contains code from: biome_lib --- Looked at code from: default ------------------------------------------------------------------------------------------------ - -abstract_dryplants.grow_grass_variation = function(pos) - local right_here = {x=pos.x, y=pos.y, z=pos.z} - minetest.swap_node(right_here, {name="dryplants:grass_short"}) -end - -biome_lib.register_on_generate({ - surface = { +-- @reviewer: couldn't even find using biome_lib +minetest.register_decoration({ + decoration = {"dryplants:grass_short"}, + fill_ratio = 0.8, + y_min = 1, + y_max = 40, + place_on = { "default:dirt_with_grass", }, - max_count = 4800, - rarity = 25, - min_elevation = 1, -- above sea level - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_grass_variation -) + deco_type = "simple", + flags = "all_floors" +}) diff --git a/dryplants/mod.conf b/dryplants/mod.conf index 3011ab6..e190197 100644 --- a/dryplants/mod.conf +++ b/dryplants/mod.conf @@ -1,3 +1,3 @@ name = dryplants -depends = default, biome_lib +depends = default optional_depends = farming diff --git a/dryplants/moregrass.lua b/dryplants/moregrass.lua index 2f574a4..5e27a9c 100644 --- a/dryplants/moregrass.lua +++ b/dryplants/moregrass.lua @@ -1,30 +1,20 @@ ------------------------------------------------------------------------------------------------ --- Grasses - More Tall Grass 0.0.2 ------------------------------------------------------------------------------------------------ --- by Mossmanikin - --- Contains code from: biome_lib --- Looked at code from: default ------------------------------------------------------------------------------------------------ - -biome_lib.register_on_generate( - { - surface = { - "default:dirt_with_grass", - "stoneage:grass_with_silex", - "sumpf:peat", - "sumpf:sumpf" - }, - max_count = 4800, - rarity = 101 - 75, - min_elevation = 1, -- above sea level - plantlife_limit = -0.9, - check_air = true, - }, - { "default:grass_1", +minetest.register_decoration({ + decoration = { + "default:grass_1", "default:grass_2", "default:grass_3", "default:grass_4", "default:grass_5" - } -) + }, + fill_ratio = 0.8, + y_min = 1, + y_max = 40, + place_on = { + "default:dirt_with_grass", + "stoneage:grass_with_silex", + "sumpf:peat", + "sumpf:sumpf" + }, + deco_type = "simple", + flags = "all_floors" +}) diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index e9547be..79054c0 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -1,13 +1,3 @@ ------------------------------------------------------------------------------------------------ --- Grasses - Reedmace 0.1.1 ------------------------------------------------------------------------------------------------ --- by Mossmanikin --- textures & ideas partly by Neuromancer - --- Contains code from: biome_lib --- Looked at code from: default, trees ------------------------------------------------------------------------------------------------ - -- NOTES (from wikipedia, some of this might get implemented) -- rhizomes are edible -- outer portion of young plants can be peeled and the heart can be eaten raw or boiled and eaten like asparagus @@ -24,14 +14,16 @@ local S = minetest.get_translator("dryplants") -- REEDMACE SHAPES ----------------------------------------------------------------------------------------------- -abstract_dryplants.grow_reedmace = function(pos) +local function grow_reedmace(pos) local size = math.random(1,3) local spikes = math.random(1,3) local pos_01 = {x = pos.x, y = pos.y + 1, z = pos.z} local pos_02 = {x = pos.x, y = pos.y + 2, z = pos.z} local pos_03 = {x = pos.x, y = pos.y + 3, z = pos.z} - if minetest.get_node(pos_01).name == "air" -- bug fix - or minetest.get_node(pos_01).name == "dryplants:reedmace_sapling" then + + local nodename = minetest.get_node(pos_01).name + if nodename == "air" -- bug fix + or nodename == "dryplants:reedmace_sapling" then if minetest.get_node(pos_02).name ~= "air" then minetest.swap_node(pos_01, {name="dryplants:reedmace_top"}) elseif minetest.get_node(pos_03).name ~= "air" then @@ -50,14 +42,16 @@ abstract_dryplants.grow_reedmace = function(pos) end end -abstract_dryplants.grow_reedmace_water = function(pos) +local function grow_reedmace_water(pos) local size = math.random(1,3) local spikes = math.random(1,3) local pos_01 = {x = pos.x, y = pos.y + 1, z = pos.z} local pos_02 = {x = pos.x, y = pos.y + 2, z = pos.z} local pos_03 = {x = pos.x, y = pos.y + 3, z = pos.z} local pos_04 = {x = pos.x, y = pos.y + 4, z = pos.z} + minetest.add_entity(pos_01, "dryplants:reedmace_water_entity") + if minetest.get_node(pos_02).name == "air" then -- bug fix if minetest.get_node(pos_03).name ~= "air" then minetest.swap_node(pos_02, {name="dryplants:reedmace_top"}) @@ -284,11 +278,11 @@ minetest.register_abm({ or string.find(minetest.get_node({x = pos.x - 1, y = pos.y, z = pos.z }).name, "default:water") or string.find(minetest.get_node({x = pos.x, y = pos.y, z = pos.z - 1}).name, "default:water") then if minetest.get_node({x = pos.x, y = pos.y + 1, z = pos.z}).name == "air" then - abstract_dryplants.grow_reedmace_water({x = pos.x, y = pos.y - 1, z = pos.z}) + grow_reedmace_water({x = pos.x, y = pos.y - 1, z = pos.z}) end minetest.swap_node({x=pos.x, y=pos.y, z=pos.z}, {name="default:water_source"}) else - abstract_dryplants.grow_reedmace({x = pos.x, y = pos.y - 1, z = pos.z}) + grow_reedmace({x = pos.x, y = pos.y - 1, z = pos.z}) end end }) @@ -326,89 +320,121 @@ minetest.register_entity("dryplants:reedmace_water_entity",{ end, }) ----------------------------------------------------------------------------------------------- --- SPAWN REEDMACE ------------------------------------------------------------------------------------------------ ---[[biome_lib.register_active_spawner({ - spawn_delay = 1200, - spawn_plants = {"dryplants:reedmace_sapling"}, - spawn_chance = 400, - spawn_surfaces = { - "default:dirt_with_grass", - "default:desert_sand", - "default:sand", - "dryplants:grass_short", - "stoneage:grass_with_silex" - }, - seed_diff = 329, - near_nodes = {"default:water_source"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, -})]] ------------------------------------------------------------------------------------------------ -- GENERATE REEDMACE ----------------------------------------------------------------------------------------------- -- near water or swamp -biome_lib.register_on_generate({ - surface = { +minetest.register_decoration({ + name = "dryplants:reedmace_swamp", + decoration = {"air"}, + fill_ratio = "0.1", + y_min = 1, + y_max = 40, + place_on = { "default:dirt_with_grass", "default:desert_sand", "stoneage:grass_with_silex", "sumpf:peat", "sumpf:sumpf" }, - max_count = 35, - rarity = 101 - 40, - --rarity = 60, - min_elevation = 1, -- above sea level - near_nodes = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_reedmace -) + deco_type = "simple", + flags = "all_floors", + spawn_by = { + "default:water_source", + "sumpf:dirtywater_source", + "sumpf:sumpf" + }, + check_offset = -1, + num_spawn_by = 1 +}) + -- in water -biome_lib.register_on_generate({ - surface = { +minetest.register_decoration({ + name = "dryplants:reedmace_water", + decoration = {"air"}, + fill_ratio = "0.01", + y_min = 0, + y_max = 0, + place_on = { "default:dirt", "default:dirt_with_grass", - --"default:desert_sand", - --"stoneage:grass_with_silex", "stoneage:sand_with_silex", "sumpf:peat", "sumpf:sumpf" }, - max_count = 35, - rarity = 101 - 65, - --rarity = 35, - min_elevation = 0, -- a bit below sea level - max_elevation = 0, -- "" - near_nodes = {"default:water_source","sumpf:dirtywater_source"}, - near_nodes_size = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_reedmace_water -) + deco_type = "simple", + flags = "all_floors", + spawn_by = { + "default:water_source", + "sumpf:dirtywater_source" + }, + check_offset = -1, + num_spawn_by = 1 +}) + -- for oases & tropical beaches & tropical swamps -biome_lib.register_on_generate({ - surface = { +minetest.register_decoration({ + name = "dryplants:reedmace_beach", + decoration = {"air"}, + fill_ratio = "0.1", + y_min = 1, + y_max = 40, + place_on = { "default:sand", "sumpf:sumpf" }, - max_count = 35, - rarity = 101 - 90, - --rarity = 10, - neighbors = {"default:water_source","sumpf:dirtywater_source","sumpf:sumpf"}, - ncount = 1, - min_elevation = 1, -- above sea level - near_nodes = {"default:desert_sand","sumpf:sumpf"}, - near_nodes_size = 2, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - abstract_dryplants.grow_reedmace -) + deco_type = "simple", + flags = "all_floors", + spawn_by = { + "default:water_source", + "sumpf:dirtywater_source", + "sumpf:sumpf", + "default:desert_sand" + }, + check_offset = -1, + num_spawn_by = 1 +}) + +local did, did2, did3 +minetest.register_on_mods_loaded(function() + did = minetest.get_decoration_id("dryplants:reedmace_swamp") + did2 = minetest.get_decoration_id("dryplants:reedmace_water") + did3 = minetest.get_decoration_id("dryplants:reedmace_beach") + minetest.set_gen_notify("decoration", {did, did2, did3}) +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations_1 = g["decoration#" .. did] or {} + local deco_locations_3 = g["decoration#" .. did3] or {} + + for _, pos in pairs(deco_locations_1) do + locations[#locations+1] = pos + end + for _, pos in pairs(deco_locations_3) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + print(minetest.pos_to_string(pos)) + grow_reedmace(pos) + end +end) + +minetest.register_on_generated(function(minp, maxp, blockseed) + local g = minetest.get_mapgen_object("gennotify") + local locations = {} + + local deco_locations_2 = g["decoration#" .. did2] or {} + + for _, pos in pairs(deco_locations_2) do + locations[#locations+1] = pos + end + + if #locations == 0 then return end + for _, pos in ipairs(locations) do + grow_reedmace_water(pos) + end +end) From 9aa5d85218f5de2d32782365fb7a1769340d05f4 Mon Sep 17 00:00:00 2001 From: Niklp09 <89982526+Niklp09@users.noreply.github.com> Date: Thu, 26 Oct 2023 19:52:30 +0200 Subject: [PATCH 21/25] Reduce reemace spawn chance --- dryplants/reedmace.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index 79054c0..d4771ee 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -326,7 +326,7 @@ minetest.register_entity("dryplants:reedmace_water_entity",{ minetest.register_decoration({ name = "dryplants:reedmace_swamp", decoration = {"air"}, - fill_ratio = "0.1", + fill_ratio = "0.05", y_min = 1, y_max = 40, place_on = { @@ -375,7 +375,7 @@ minetest.register_decoration({ minetest.register_decoration({ name = "dryplants:reedmace_beach", decoration = {"air"}, - fill_ratio = "0.1", + fill_ratio = "0.05", y_min = 1, y_max = 40, place_on = { From fc1d05978e229cb9858aa14d5786a8049a892107 Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Fri, 27 Oct 2023 03:29:04 -0400 Subject: [PATCH 22/25] Remove biome lib from pl_waterlilies (#65) * remove biome lib from pl_waterlilies * Add rarity setting --------- Co-authored-by: Niklp09 <89982526+Niklp09@users.noreply.github.com> --- pl_waterlilies/init.lua | 90 +++++++++++++++++++-------------- pl_waterlilies/mod.conf | 1 - pl_waterlilies/settingtypes.txt | 7 +-- 3 files changed, 54 insertions(+), 44 deletions(-) diff --git a/pl_waterlilies/init.lua b/pl_waterlilies/init.lua index 491a39a..430dcc5 100644 --- a/pl_waterlilies/init.lua +++ b/pl_waterlilies/init.lua @@ -1,10 +1,7 @@ -- support for i18n local S = minetest.get_translator("pl_waterlilies") -pl_waterlilies = {} - -local lilies_max_count = tonumber(minetest.settings:get("pl_waterlilies_max_count")) or 320 -local lilies_rarity = tonumber(minetest.settings:get("pl_waterlilies_rarity")) or 33 +local fill_ratio = minetest.settings:get("pl_waterlilies.waterlily_rarity") or 0.03 local function get_ndef(name) return minetest.registered_nodes[name] or {} @@ -21,6 +18,15 @@ local lilies_list = { { "s4" , "small_4" , 8 }, } +local lilynames_list = {} +for i in ipairs(lilies_list) do + local deg1 = "" + if lilies_list[i][1] ~= nil then + deg1 = "_"..lilies_list[i][1] + end + table.insert(lilynames_list, "flowers:waterlily"..deg1) +end + for i in ipairs(lilies_list) do local deg1 = "" local deg2 = "" @@ -124,42 +130,50 @@ for i in ipairs(lilies_list) do end end, }) + + minetest.register_decoration({ + name = "flowers:waterlily"..deg1, + decoration = {"flowers:waterlily"..deg1}, + place_on = {"default:water_source"}, + deco_type = "simple", + flags = "liquid_surface", + spawn_by = "default:sand", + num_spawn_by = 1, + fill_ratio = fill_ratio, + check_offset = -1, + y_min = 1, + y_max = 1, + }) + + minetest.register_decoration({ + name = "flowers:waterlily"..deg1 .."_relative", + decoration = {"flowers:waterlily"..deg1}, + place_on = {"default:water_source"}, + deco_type = "simple", + flags = "liquid_surface", + spawn_by = lilynames_list, + num_spawn_by = 1, + fill_ratio = fill_ratio*1.25, + check_offset = -1, + y_min = 1, + y_max = 1, + }) + + minetest.register_decoration({ + name = "flowers:waterlily"..deg1 .."_relative", + decoration = {"flowers:waterlily"..deg1}, + place_on = {"default:water_source"}, + deco_type = "simple", + flags = "liquid_surface", + spawn_by = lilynames_list, + num_spawn_by = 1, + fill_ratio = fill_ratio*1.5, + check_offset = -1, + y_min = 1, + y_max = 1, + }) end -pl_waterlilies.grow_waterlily = function(pos) - local right_here = {x=pos.x, y=pos.y+1, z=pos.z} - for i in ipairs(lilies_list) do - local chance = math.random(1,8) - local ext = "" - local num = lilies_list[i][3] - - if lilies_list[i][1] ~= nil then - ext = "_"..lilies_list[i][1] - end - - if chance == num then - minetest.swap_node(right_here, {name="flowers:waterlily"..ext, param2=math.random(0,3)}) - end - end -end - -biome_lib.register_on_generate({ - surface = {"default:water_source"}, - max_count = lilies_max_count, - rarity = lilies_rarity, - min_elevation = 1, - max_elevation = 40, - near_nodes = {"default:dirt_with_grass"}, - near_nodes_size = 4, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - temp_max = -0.22, - temp_min = 0.22, - }, - pl_waterlilies.grow_waterlily -) - minetest.register_alias( "flowers:flower_waterlily", "flowers:waterlily") minetest.register_alias( "flowers:flower_waterlily_225", "flowers:waterlily_225") minetest.register_alias( "flowers:flower_waterlily_45", "flowers:waterlily_45") diff --git a/pl_waterlilies/mod.conf b/pl_waterlilies/mod.conf index 5233adb..3e96eb3 100644 --- a/pl_waterlilies/mod.conf +++ b/pl_waterlilies/mod.conf @@ -1,3 +1,2 @@ name = pl_waterlilies -depends = biome_lib optional_depends = farming, flowers diff --git a/pl_waterlilies/settingtypes.txt b/pl_waterlilies/settingtypes.txt index 523a677..c0e1062 100644 --- a/pl_waterlilies/settingtypes.txt +++ b/pl_waterlilies/settingtypes.txt @@ -1,5 +1,2 @@ -#Water-lilies maximum count -pl_waterlilies_max_count (Water-lilies maximum count) int 320 1 1000 - -#Water-lilies rarity -pl_waterlilies_rarity (Water-lilies rarity) int 33 0 100 +# Waterlily rarity (higher number -> higher probability) +pl_waterlilies.waterlily_rarity (Waterlily rarity) float 0.03 0.0001 1 From e9eb1f51e8bc27738d7a1525a793a6dda74ce4cc Mon Sep 17 00:00:00 2001 From: Niklp09 <89982526+Niklp09@users.noreply.github.com> Date: Fri, 27 Oct 2023 13:47:52 +0200 Subject: [PATCH 23/25] Re-add `grow_reedmace` to global namespace --- dryplants/init.lua | 2 ++ dryplants/reedmace.lua | 2 ++ 2 files changed, 4 insertions(+) diff --git a/dryplants/init.lua b/dryplants/init.lua index 5b808c0..2aec66c 100644 --- a/dryplants/init.lua +++ b/dryplants/init.lua @@ -1,6 +1,8 @@ -- support for i18n local S = minetest.get_translator("dryplants") +abstract_dryplants = {} + dofile(minetest.get_modpath("dryplants").."/crafting.lua") dofile(minetest.get_modpath("dryplants").."/reed.lua") diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index d4771ee..6ecdbde 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -71,6 +71,8 @@ local function grow_reedmace_water(pos) end end +abstract_dryplants.grow_reedmace = grow_reedmace -- compatibility + ----------------------------------------------------------------------------------------------- -- REEDMACE SPIKES ----------------------------------------------------------------------------------------------- From a6c8e4a9d3779a1d59a888a7432b9946e901d9e9 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Fri, 27 Oct 2023 17:45:01 +0200 Subject: [PATCH 24/25] Remove biome_lib dep from pl_seaweed (#64) * Remove biome_lib dep from pl_seaweed * Push changes (new approach tomorrow) * no.2 Co-authored-by: wsor4035 <24964441+wsor4035@users.noreply.github.com> --- dryplants/reedmace.lua | 1 - pl_seaweed/init.lua | 93 ++++++++++++------------------------- pl_seaweed/mod.conf | 1 - pl_seaweed/settingtypes.txt | 7 +-- 4 files changed, 31 insertions(+), 71 deletions(-) diff --git a/dryplants/reedmace.lua b/dryplants/reedmace.lua index 6ecdbde..cad82c2 100644 --- a/dryplants/reedmace.lua +++ b/dryplants/reedmace.lua @@ -420,7 +420,6 @@ minetest.register_on_generated(function(minp, maxp, blockseed) if #locations == 0 then return end for _, pos in ipairs(locations) do - print(minetest.pos_to_string(pos)) grow_reedmace(pos) end end) diff --git a/pl_seaweed/init.lua b/pl_seaweed/init.lua index b5456c7..b99f19a 100644 --- a/pl_seaweed/init.lua +++ b/pl_seaweed/init.lua @@ -1,10 +1,7 @@ -- support for i18n local S = minetest.get_translator("pl_seaweed") -pl_seaweed = {} - -local seaweed_max_count = tonumber(minetest.settings:get("pl_seaweed_max_count")) or 320 -local seaweed_rarity = tonumber(minetest.settings:get("pl_seaweed_rarity")) or 33 +local seaweed_rarity = minetest.settings:get("pl_seaweed.seaweed_rarity") or 0.06 local function get_ndef(name) return minetest.registered_nodes[name] or {} @@ -105,68 +102,36 @@ for i in ipairs(algae_list) do end end, }) + + minetest.register_decoration({ + name = "flowers:seaweed"..num, + decoration = {"flowers:seaweed"..num}, + place_on = {"default:water_source"}, + deco_type = "simple", + flags = "liquid_surface", + spawn_by = {"default:dirt_with_grass", "default:sand"}, + num_spawn_by = 1, + fill_ratio = seaweed_rarity, + check_offset = -1, + y_min = 1, + y_max = 1, + }) + + minetest.register_decoration({ + name = "flowers:seaweed"..num .."_sand", + decoration = {"flowers:seaweed"..num}, + place_on = {"default:sand"}, + deco_type = "simple", + flags = "all_floors", + spawn_by = "default:water_source", + num_spawn_by = 1, + fill_ratio = seaweed_rarity*1.2, + check_offset = -1, + y_min = 1, + y_max = 1, + }) end -pl_seaweed.grow_seaweed = function(pos) - local right_here = {x=pos.x, y=pos.y+1, z=pos.z} - local seaweed = math.random(1,4) - local node_name = "flowers:seaweed" - if seaweed > 1 then - node_name = node_name .. "_" .. seaweed - end - minetest.swap_node(right_here, {name=node_name, param2=math.random(1,3)}) -end - -biome_lib.register_on_generate({ - surface = {"default:water_source"}, - max_count = seaweed_max_count, - rarity = seaweed_rarity, - min_elevation = 1, - max_elevation = 40, - near_nodes = {"default:dirt_with_grass"}, - near_nodes_size = 4, - near_nodes_vertical = 1, - near_nodes_count = 1, - plantlife_limit = -0.9, - }, - pl_seaweed.grow_seaweed -) - --- pl_seaweed at beaches --- MM: not satisfied with it, but IMHO some beaches should have some algae -biome_lib.register_on_generate({ - surface = {"default:water_source"}, - max_count = seaweed_max_count, - rarity = seaweed_rarity, - min_elevation = 1, - max_elevation = 40, - near_nodes = {"default:sand"}, - near_nodes_size = 1, - near_nodes_vertical = 0, - near_nodes_count = 3, - plantlife_limit = -0.9, - temp_max = -0.64, -- MM: more or less random values, just to make sure it's not everywhere - temp_min = -0.22, -- MM: more or less random values, just to make sure it's not everywhere - }, - pl_seaweed.grow_seaweed -) -biome_lib.register_on_generate({ - surface = {"default:sand"}, - max_count = seaweed_max_count*2, - rarity = seaweed_rarity/2, - min_elevation = 1, - max_elevation = 40, - near_nodes = {"default:water_source"}, - near_nodes_size = 1, - near_nodes_vertical = 0, - near_nodes_count = 3, - plantlife_limit = -0.9, - temp_max = -0.64, -- MM: more or less random values, just to make sure it's not everywhere - temp_min = -0.22, -- MM: more or less random values, just to make sure it's not everywhere - }, - pl_seaweed.grow_seaweed -) - minetest.register_alias("flowers:flower_seaweed", "flowers:seaweed") minetest.register_alias("along_shore:pondscum_1", "flowers:seaweed") minetest.register_alias("along_shore:seaweed_1", "flowers:seaweed") diff --git a/pl_seaweed/mod.conf b/pl_seaweed/mod.conf index ed99972..73a791c 100644 --- a/pl_seaweed/mod.conf +++ b/pl_seaweed/mod.conf @@ -1,3 +1,2 @@ name = pl_seaweed -depends = biome_lib optional_depends = farming, flowers diff --git a/pl_seaweed/settingtypes.txt b/pl_seaweed/settingtypes.txt index 3cb8772..8c073c5 100644 --- a/pl_seaweed/settingtypes.txt +++ b/pl_seaweed/settingtypes.txt @@ -1,5 +1,2 @@ -#Seaweed maximum count -pl_seaweed_max_count (Seaweed maximum count) int 320 1 1000 - -#Seaweed rarity -pl_seaweed_rarity (Seaweed rarity) int 33 0 100 +# Seaweed rarity (higher number -> higher probability) +pl_seaweed.seaweed_rarity (Seaweed rarity) float 0.06 0.0001 1 From 54a3e1d98b5c8902b7608497795712967b6efffc Mon Sep 17 00:00:00 2001 From: wsor4035 <24964441+wsor4035@users.noreply.github.com> Date: Fri, 3 Nov 2023 16:20:01 -0400 Subject: [PATCH 25/25] patch ebiomes being bad by loading after it (#67) --- bushes/mod.conf | 2 +- dryplants/mod.conf | 2 +- youngtrees/mod.conf | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/bushes/mod.conf b/bushes/mod.conf index 822e050..5ebb64d 100644 --- a/bushes/mod.conf +++ b/bushes/mod.conf @@ -1,4 +1,4 @@ name = bushes title = Bushes depends = default -optional_depends = stoneage, sumpf +optional_depends = stoneage, sumpf, ebiomes diff --git a/dryplants/mod.conf b/dryplants/mod.conf index e190197..e42d8ab 100644 --- a/dryplants/mod.conf +++ b/dryplants/mod.conf @@ -1,3 +1,3 @@ name = dryplants depends = default -optional_depends = farming +optional_depends = farming, ebiomes diff --git a/youngtrees/mod.conf b/youngtrees/mod.conf index b5b1250..5a8e9fb 100644 --- a/youngtrees/mod.conf +++ b/youngtrees/mod.conf @@ -1,2 +1,3 @@ name = youngtrees depends = default +optional_depends = ebiomes