1
0
mirror of https://github.com/mt-mods/plantlife_modpack.git synced 2025-06-30 15:10:34 +02:00

72 Commits

Author SHA1 Message Date
99d58e0876 add pl.generate_noise_params() 2023-04-16 19:24:52 +02:00
59c483fd4f support avoid_nodes 2023-04-13 21:15:34 +02:00
640cfd3ac7 improve near_nodes support 2023-04-13 14:15:10 +02:00
cdfbf20ab0 experimental near_nodes support 2023-04-12 21:54:22 +02:00
85569605f5 spawn some more plants directly 2023-04-12 21:03:22 +02:00
a154cb9904 disable some logging 2023-04-12 17:52:29 +02:00
d55f066686 support youngtrees 2023-04-12 17:34:48 +02:00
252c2bd1d2 add support for custom spawn functions 2023-04-12 17:00:18 +02:00
15f62452b8 some biome_lib replacement experiments 2023-04-12 14:12:51 +02:00
577404c850 fix https://github.com/mt-mods/plantlife_modpack/issues/38 - add use_texture_alpa param to nodes that have textures with alpa 2023-01-21 15:48:24 -05:00
a2cbc18351 fix upside-down vines ends (#37) 2022-11-12 20:22:16 -05:00
9483fee7b3 Added Esperanto translation (#36)
used the template.txt's
2022-11-06 12:53:16 -05:00
1894d91609 add node dig/placement predictions (#34) 2022-11-04 12:29:34 -04:00
438a1adb32 limit bush duping (#33)
only allow a chance of getting a 2nd bush from bushes with fruit, to prevent instant bush duping.
2022-11-04 12:28:33 -04:00
e159b843d2 restrict tree fern growth (#32) 2022-10-30 17:57:12 -04:00
6e842d9b0d add bush leaves to leaves group (#31) 2022-10-10 18:39:58 +02:00
8287ae2476 Add German translation (#29)
* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German transaltion

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add German translation

Add German translation

* Add support for i18n

Add support for i18n, make loading translateable

* Add template for translation

* Add German translation

Add German translation
2022-09-01 21:02:37 -04:00
ca2b47492e Merge pull request #28 from Niklp09/mushroom
overwrite wield_image's of mushrooms
2022-08-19 15:06:41 +02:00
f5490e3b58 overwrite wield_images's 2022-08-19 14:53:39 +02:00
bde2082ee1 Texture update for vines to CC0 (#21)
* Texture update for vines to CC0

recreated the vines and rope textures and releasing them under CC0

* Minor tweaks to textures
2022-06-24 14:32:09 +03:00
d33907ca75 Fix typo in crafting recipes in trunks
Fixes #24 
Co-authored-by: A S Lewis <aslewis@cpan.org>
2022-06-08 22:03:52 +10:00
244d5da0e2 wear too when breaking vines (#22) 2022-05-28 17:35:42 -04:00
8de8b889c2 fix typo in bushes mod.conf
fixes #17
2022-05-09 23:10:56 +10:00
1d71e2c64e fix https://github.com/mt-mods/plantlife_modpack/issues/16 2022-03-19 17:04:06 -04:00
d3edfbeace Merge pull request #14 from nixnoxus/fix_tree_fern_leave_big
fix felling `farns:fern_trunk_big`
2022-01-11 22:19:26 -05:00
c82ba38e68 Merge pull request #15 from nixnoxus/add_group_sapling
Add `group:sapling` for saplings in plantlife
2022-01-11 17:18:14 -05:00
031d5f4e4e add group sapling 2022-01-11 18:55:22 +01:00
32bab30e1f fix felling farns: fern_trunk_big 2022-01-10 19:32:04 +01:00
7094d8a369 Vines: Fix recipes and global variables (#13) 2021-12-28 14:45:05 +11:00
c990942ba2 fix https://github.com/mt-mods/plantlife_modpack/issues/11 2021-12-25 21:44:43 -05:00
4953b1ba54 Rarity / fertility tweaks for various mods (#8)
For bushes, molehills and youngtrees:
Changes to rarity and minimum fertility. Also added use of rarity_fertility. Result is more balanced and less homogeneous, i.e. over a large area you'll see variation.

For vines, some further tweaks to rarity, and using tries field to improve vines distribution.
2021-12-24 09:31:30 +01:00
cb2373f089 Trunks: Prevent crashing when unknown nodes exist (#9)
Extension of commit 9ed4771515

Co-authored-by: OgelGames <olliverdc28@gmail.com>
2021-12-16 20:10:36 +11:00
1a96ac87a7 Breaking up flowers_plus mod (#5)
Splitting up flowers_plus into separate mods for seaweed, sunflowers and waterlillies, for clarity and so the user can disable them individually.
Fixed sunflower maximum heat.
Removed spawning, as we're already creating these things at worldgen.
Added settings for rarity and max count to each mod - waterlilies, seaweed and sunflowers
Removing along_shore mod as it does nothing now.
2021-12-14 13:05:23 +01:00
a6dc4890d9 Vines: Fixed humidity, and set temperature. Also fixed a couple of issues with spawning: Roots are meant to spawn under dirt blocks, also vines were appearing on the side of snow. 2021-12-11 19:45:25 +01:00
a5b752f8b2 Merge pull request #3 from JordanL2/vines_mapgen
Vines overhaul
2021-12-07 17:21:17 -05:00
4c48e5be29 Update vines/init.lua
Co-authored-by: SX <50966843+S-S-X@users.noreply.github.com>
2021-12-07 22:19:57 +00:00
a7d0e42cd1 Update vines/init.lua
Co-authored-by: SX <50966843+S-S-X@users.noreply.github.com>
2021-12-07 22:19:49 +00:00
2e4e4a2412 Replace vines with air if they've been disabled for compatibility 2021-12-06 10:56:05 +00:00
1d3751d755 Avoid one node vines on top of trees. 2021-12-06 10:55:42 +00:00
e2486ca7f5 Adding default to boolean settings 2021-12-06 09:33:44 +00:00
98f0c6c20f Slight simplification of on_dig. Also minor fix to generating vines of a certain length. 2021-12-05 11:41:49 +00:00
54d3b669be Vines: Simplifying digging logic. 2021-12-05 11:08:51 +00:00
93265656cc Adding vine growth speed settings 2021-12-04 20:28:11 +00:00
c76fd45a2c Option to disable vines:vines item, as it seems pointless.
All recipes allow the vines group, so any vine end item will work.
2021-12-04 20:17:44 +00:00
c7d0fd3c53 Cutting vines with shears now gives the player the vine ends, so they can make their own vine farm 2021-12-04 18:53:39 +00:00
a66b82f1f0 Fixing growth. Vines now grow once every 3-6 minutes. 2021-12-04 17:56:28 +00:00
63914caed1 Removing attached_node from vine groups, as it was causing breaking one vine to break the vine all the way up to the top, instantly 2021-12-04 17:56:28 +00:00
ba98359dd0 When a vine is destroyed, ensure the remaining part of the vine ends with a vine end node. 2021-12-04 17:56:28 +00:00
6df36da4e1 Settings to disable any type of vine and vine rope. Settings to adjust rarity of vines. 2021-12-04 17:55:49 +00:00
28ef3e0c4b Vines now generated at mapgen time. Vines now generated as a vine of random length. 2021-12-04 17:55:08 +00:00
680b02f7e2 fix crash for sure this time 2021-07-19 23:56:47 -04:00
a2976c609a update all generate, spawn, and grow calls
to use "." instead of ":" notation
(quells all those "deprecated" warnings)
2021-07-19 14:18:01 -04:00
46717958bc use biome_lib.get_nodedef_field
instead of biome_lib:get_nodedef_field
(change `.` to `:`)
2021-07-19 14:08:57 -04:00
52b2d18523 make moss buildable_to
and make sunflower attached_node like other plants
2021-06-29 13:44:00 -04:00
bfd08f01c8 Just run the conversion LBM on every load
it won't take any appreciable CPU anyway if there's nothing to do.

Minetest seems to not new (or newly-renamed) LBMs when it should, when
it's set to only run once.  Also covers cases where a crash could
prevent mapblocks being checked later.
2021-06-23 21:09:48 -04:00
9ed4771515 fix rare edge-case where unknown nodes cause a crash
When a new mapblock is generated and the mod checks the neighbors around
a target to place a fallen twig, if it finds an unknown node (because
it's in a neighboring, old mapblock from a previous session -- perhaps
an old moss node that hadn't converted-over to wallmounted yet), trying
to check its buildable_to state will fail, since that requires that
there be a node def to look at, which an unknown node wouldn't have.

This substitutes a known not-buildable_to node for those cases, so that
the code won't try to overwrite what it found.
2021-06-23 21:03:06 -04:00
3f107a8067 renamed the LBM in case it got run at the wrong time
between mod updates; forces it to run again
(it's harmless to let it run twice)
2021-06-23 10:09:58 -04:00
b3cbd3df2e fix moss node drops 2021-06-21 05:21:34 -04:00
b1b4a08834 make pebbles fall when ground is dug. 2021-06-21 00:36:14 -04:00
f01e4bb55f Convert moss to wallmounted mode
I couldn't use leaf decay to make moss disappear when a trunk is dug,
because it breaks leaf decay on that tree's leaves: the leafdecay
function is not a true "register"- type function that can be run more
than once on a given trunk node, it's an all-or-nothing override and
only the last call for any given trunk actually sticks.

Since moss is... was facedir, attached_node didn't work right either, as
it doesn't have a mode to look for a vertical surface behind the
attached object (like how it works with wallmounted items), so this
converts moss to true wallmounted and uses attached_node like I
originally wanted.

To avoid losing the effect where moss can be rotated randomly when
generated, I registered 4 nodes for each moss type, with
increasingly-rotated textures.
2021-06-20 23:30:26 -04:00
7b4f54ead0 make youngtrees, bushes fall on dig,
make moss fall when the node holding it is dug,
and make trunk roots decay (exploiting the standard leafdecay function)
2021-06-19 20:36:36 -04:00
c061ef23cf Merge branch 'bls-197' into 'master'
Fixes bug with stalactite placement

See merge request VanessaE/plantlife_modpack!7
2021-06-07 17:04:31 +00:00
d87d8e51f5 Fixes bug with stalactite placement 2021-06-07 17:04:31 +00:00
70df655a42 allow pebbles to spawn on a few more surface types 2021-04-06 04:09:34 -04:00
4876fc1265 let biome_lib place pebbles instead of using custom mapgen code 2021-04-06 04:08:41 -04:00
81b2b0898b don't use a function to pick random dry grasses
just use `biome_lib`'s random-choice table feature
(it was only there to let the mod replace junglegrass, but that's pointless
when junglegrass doesn't tend to spawn in the same areas)
2021-04-06 03:32:04 -04:00
a750bac532 Merge branch 'master' into 'master'
Made woodsoils soils tillable.

See merge request VanessaE/plantlife_modpack!6
2021-02-07 23:29:08 +00:00
b4b24dedba Made woodsoils soils tillable. 2021-02-07 21:17:29 +01:00
622016713e respect protection when placing twigs 2020-12-02 10:05:01 -05:00
9963e588d6 add minimum minetest version key for contentdb 2020-06-03 13:00:31 -04:00
686dd21b9d Merge branch 'mt5-locale' into 'master'
MT5 locale

See merge request VanessaE/plantlife_modpack!5
2020-02-15 14:32:06 +00:00
47c20dc550 Remove translations in minetest.log output
because they are not translated anyway
2020-02-15 14:32:06 +00:00
224 changed files with 2954 additions and 4438 deletions

View File

@ -9,7 +9,6 @@ read_globals = {
"vector", "nodeupdate", "vector", "nodeupdate",
"VoxelManip", "VoxelArea", "VoxelManip", "VoxelArea",
"PseudoRandom", "ItemStack", "PseudoRandom", "ItemStack",
"intllib",
"default", "default",
} }

View File

@ -1,2 +0,0 @@
default
flowers

View File

@ -2,6 +2,9 @@
mushroom = {} mushroom = {}
-- support for i18n
local S = minetest.get_translator("3dmushrooms")
minetest.override_item("flowers:mushroom_fertile_brown", { minetest.override_item("flowers:mushroom_fertile_brown", {
drawtype = "mesh", drawtype = "mesh",
mesh = "3dmushrooms.obj", mesh = "3dmushrooms.obj",
@ -10,7 +13,8 @@ minetest.override_item("flowers:mushroom_fertile_brown", {
type = "fixed", type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3}
}, },
inventory_image = "3dmushrooms_brown_inv.png" inventory_image = "3dmushrooms_brown_inv.png",
wield_image = "3dmushrooms_brown_inv.png"
}) })
minetest.override_item("flowers:mushroom_brown", { minetest.override_item("flowers:mushroom_brown", {
@ -21,7 +25,8 @@ minetest.override_item("flowers:mushroom_brown", {
type = "fixed", type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3}
}, },
inventory_image = "3dmushrooms_brown_inv.png" inventory_image = "3dmushrooms_brown_inv.png",
wield_image = "3dmushrooms_brown_inv.png"
}) })
minetest.override_item("flowers:mushroom_fertile_red", { minetest.override_item("flowers:mushroom_fertile_red", {
@ -32,7 +37,8 @@ minetest.override_item("flowers:mushroom_fertile_red", {
type = "fixed", type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3}
}, },
inventory_image = "3dmushrooms_red_inv.png" inventory_image = "3dmushrooms_red_inv.png",
wield_image = "3dmushrooms_red_inv.png"
}) })
minetest.override_item("flowers:mushroom_red", { minetest.override_item("flowers:mushroom_red", {
@ -43,7 +49,8 @@ minetest.override_item("flowers:mushroom_red", {
type = "fixed", type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3}
}, },
inventory_image = "3dmushrooms_red_inv.png" inventory_image = "3dmushrooms_red_inv.png",
wield_image = "3dmushrooms_red_inv.png"
}) })
-- aliases to the default mushrooms -- aliases to the default mushrooms
@ -62,4 +69,4 @@ minetest.register_alias("mushroom:poison", "flowers:mushroom_red")
minetest.register_alias("mushroom:identifier", "default:mese_crystal_fragment") minetest.register_alias("mushroom:identifier", "default:mese_crystal_fragment")
print("[3D Mushrooms] loaded.") minetest.log("info", S("[3D Mushrooms] loaded."))

View File

@ -0,0 +1,8 @@
# 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.

View File

@ -0,0 +1,8 @@
# 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.

View File

@ -0,0 +1,8 @@
# 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 <EMAIL@ADDRESS>, YEAR.
[3D Mushrooms] loaded.=

2
3dmushrooms/mod.conf Normal file
View File

@ -0,0 +1,2 @@
name = 3dmushrooms
depends = default, flowers

View File

@ -1,3 +0,0 @@
default
biome_lib
flowers_plus?

View File

@ -1,9 +0,0 @@
-----------------------------------------------------------------------------------------------
local title = "Along the Shore"
local version = "0.0.4"
local mname = "along_shore"
-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------
print("[Mod] "..title.." ["..version.."] ["..mname.."] Loaded...")
-----------------------------------------------------------------------------------------------

Binary file not shown.

Before

Width:  |  Height:  |  Size: 234 B

View File

@ -1,30 +0,0 @@
-------------------------------------------------------------
Credit for textures of "along_shore"
-------------------------------------------------------------
(If more than one author is listed the names are in alphabetical order)
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FOLDER TEXTURE AUTHORS
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
../along_shore/textures along_shore_seaweed_1Darker.png Neuromancer, VanessaE
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
../along_shore/textures/old (along_shore_empty.png) (Mossmanikin)
along_shore_lilypads_1.png Mossmanikin, Neuromancer
along_shore_lilypads_2.png Mossmanikin, Neuromancer
along_shore_lilypads_3.png Mossmanikin, Neuromancer
along_shore_lilypads_4.png Mossmanikin, Neuromancer
along_shore_pondscum_1.png Neuromancer
along_shore_seaweed_1.png Neuromancer, VanessaE
along_shore_seaweed_2.png Mossmanikin, Neuromancer, VanessaE
along_shore_seaweed_3.png Mossmanikin, Neuromancer, VanessaE
along_shore_seaweed_4.png Mossmanikin, Neuromancer, VanessaE
flowers_seaweed.png Neuromancer, VanessaE
flowers_waterlily.png Mossmanikin, VanessaE
flowers_waterlily_22.5.png Mossmanikin, VanessaE
flowers_waterlily_45.png Mossmanikin, VanessaE
flowers_waterlily_67.5.png Mossmanikin, VanessaE
lillypad3Flower16x.png Neuromancer
LillyPad3x16.png Neuromancer
lillyPad5x16.png Neuromancer
MultiLilly16x.png Neuromancer
pondscum16xc.png Neuromancer
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Binary file not shown.

Before

Width:  |  Height:  |  Size: 439 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 305 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 305 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 382 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 314 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 209 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 543 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 222 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 224 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 226 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 178 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 222 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 404 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 429 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 424 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 427 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 308 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 411 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 543 B

View File

@ -1,5 +0,0 @@
default
biome_lib
plantlife_i18n
stonage?
sumpf?

View File

@ -7,31 +7,38 @@
-- Branch textures created by Neuromancer. -- Branch textures created by Neuromancer.
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("bushes")
abstract_bushes = {} abstract_bushes = {}
minetest.register_node("bushes:youngtree2_bottom", { 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_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
minetest.register_node("bushes:youngtree2_bottom", {
description = S("Young Tree 2 (bottom)"), description = S("Young Tree 2 (bottom)"),
drawtype="nodebox", drawtype="nodebox",
tiles = {"bushes_youngtree2trunk.png"}, tiles = {"bushes_youngtree2trunk.png"},
inventory_image = "bushes_youngtree2trunk_inv.png", inventory_image = "bushes_youngtree2trunk_inv.png",
wield_image = "bushes_youngtree2trunk_inv.png", wield_image = "bushes_youngtree2trunk_inv.png",
paramtype = "light", paramtype = "light",
walkable = false, walkable = false,
is_ground_content = true, is_ground_content = true,
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
--{0.375000,-0.500000,-0.500000,0.500000,0.500000,-0.375000}, --NodeBox 1 --{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 {-0.0612,-0.500000,-0.500000,0.0612,0.500000,-0.375000}, --NodeBox 1
} }
}, },
groups = {snappy=3,flammable=2}, groups = {snappy=3,flammable=2,attached_node=1},
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
drop = 'default:stick' drop = 'default:stick'
}) })
local BushBranchCenter = { {1,1}, {3,2} } local BushBranchCenter = { {1,1}, {3,2} }
for i in pairs(BushBranchCenter) do for i in pairs(BushBranchCenter) do
local Num = BushBranchCenter[i][1] local Num = BushBranchCenter[i][1]
local TexNum = BushBranchCenter[i][2] local TexNum = BushBranchCenter[i][2]
@ -42,6 +49,7 @@ for i in pairs(BushBranchCenter) do
"bushes_leaves_"..TexNum..".png", "bushes_leaves_"..TexNum..".png",
"bushes_branches_center_"..TexNum..".png" "bushes_branches_center_"..TexNum..".png"
}, },
use_texture_alpha = "clip",
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
@ -55,13 +63,14 @@ for i in pairs(BushBranchCenter) do
}, },
inventory_image = "bushes_branches_center_"..TexNum..".png", inventory_image = "bushes_branches_center_"..TexNum..".png",
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
sunlight_propagates = true, sunlight_propagates = true,
groups = { groups = {
-- tree=1, -- MM: disabled because some recipes use group:tree for trunks -- tree=1, -- MM: disabled because some recipes use group:tree for trunks
snappy=3, snappy=3,
flammable=2, flammable=2,
leaves=1 leaves=1,
attached_node=1
}, },
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
drop = 'default:stick 4' drop = 'default:stick 4'
@ -80,16 +89,17 @@ for i in pairs(BushBranchSide) do
--[[bottom]]"bushes_branches_center_"..TexNum..".png", --[[bottom]]"bushes_branches_center_"..TexNum..".png",
--[[right]] "bushes_branches_left_"..TexNum..".png", --[[right]] "bushes_branches_left_"..TexNum..".png",
--[[left]] "bushes_branches_right_"..TexNum..".png", -- MM: We could also mirror the previous here, --[[left]] "bushes_branches_right_"..TexNum..".png", -- MM: We could also mirror the previous here,
--[[back]] "bushes_branches_center_"..TexNum..".png",-- unless U really want 'em 2 B different --[[back]] "bushes_branches_center_"..TexNum..".png",-- unless U really want 'em 2 B different
--[[front]] "bushes_branches_right_"..TexNum..".png" --[[front]] "bushes_branches_right_"..TexNum..".png"
}, },
use_texture_alpha = "clip",
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
-- { left , bottom , front, right , top , back } -- { left , bottom , front, right , top , back }
{0.137748,-0.491944, 0.5 ,-0.125000,-0.179444,-0.007790}, --NodeBox 1 {0.137748,-0.491944, 0.5 ,-0.125000,-0.179444,-0.007790}, --NodeBox 1
{0.262748,-0.185995, 0.5 ,-0.237252, 0.126505,-0.260269}, --NodeBox 2 {0.262748,-0.185995, 0.5 ,-0.237252, 0.126505,-0.260269}, --NodeBox 2
{0.500000, 0.125000, 0.5 ,-0.500000, 0.500000,-0.500000}, --NodeBox 3 {0.500000, 0.125000, 0.5 ,-0.500000, 0.500000,-0.500000}, --NodeBox 3
}, },
}, },
selection_box = { selection_box = {
@ -98,13 +108,14 @@ for i in pairs(BushBranchSide) do
}, },
inventory_image = "bushes_branches_right_"..TexNum..".png", inventory_image = "bushes_branches_right_"..TexNum..".png",
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
sunlight_propagates = true, sunlight_propagates = true,
groups = { groups = {
-- tree=1, -- MM: disabled because some recipes use group:tree for trunks -- tree=1, -- MM: disabled because some recipes use group:tree for trunks
snappy=3, snappy=3,
flammable=2, flammable=2,
leaves=1 leaves=1,
attached_node=1
}, },
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
drop = 'default:stick 3' drop = 'default:stick 3'
@ -118,11 +129,13 @@ for i in pairs(BushLeafNode) do
description = S("Bush Leaves @1", Num), description = S("Bush Leaves @1", Num),
drawtype = "allfaces_optional", drawtype = "allfaces_optional",
tiles = {"bushes_leaves_"..Num..".png"}, tiles = {"bushes_leaves_"..Num..".png"},
use_texture_alpha = "clip",
paramtype = "light", paramtype = "light",
groups = { -- MM: Should we add leafdecay? groups = { -- MM: Should we add leafdecay?
snappy=3, snappy=3,
flammable=2, flammable=2,
attached_node=1 attached_node=1,
leaves=1
}, },
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
}) })
@ -158,9 +171,8 @@ abstract_bushes.grow_bush = function(pos)
abstract_bushes.grow_bush_node(pos,5,leaf_type) abstract_bushes.grow_bush_node(pos,5,leaf_type)
end end
abstract_bushes.grow_bush_node = function(pos,dir, leaf_type) abstract_bushes.grow_bush_node = function(pos,dir, leaf_type)
local right_here = {x=pos.x, y=pos.y+1, z=pos.z} 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 above_right_here = {x=pos.x, y=pos.y+2, z=pos.z}
@ -182,7 +194,7 @@ abstract_bushes.grow_bush_node = function(pos,dir, leaf_type)
dir = 1 dir = 1
end end
if minetest.get_node(right_here).name == "air" -- instead of check_air = true, if minetest.get_node(right_here).name == "air" -- instead of check_air = true,
or minetest.get_node(right_here).name == "default:junglegrass" then or minetest.get_node(right_here).name == "default:junglegrass" then
minetest.swap_node(right_here, {name="bushes:bushbranches"..bush_branch_type , param2=dir}) minetest.swap_node(right_here, {name="bushes:bushbranches"..bush_branch_type , param2=dir})
--minetest.chat_send_all("leaf_type: (" .. leaf_type .. ")") --minetest.chat_send_all("leaf_type: (" .. leaf_type .. ")")
@ -197,64 +209,58 @@ abstract_bushes.grow_bush_node = function(pos,dir, leaf_type)
end end
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"stoneage:grass_with_silex", "stoneage:grass_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({rarity = bushes_bush_rarity, rarity_fertility = bushes_bush_rarity_fertility}),
min_elevation = 1, -- above sea level
}, },
max_count = 15, --10,15 "bushes:bushes",
rarity = 101 - 4, --3,4 abstract_bushes.grow_bush
min_elevation = 1, -- above sea level
plantlife_limit = -0.9,
},
abstract_bushes.grow_bush
) )
abstract_bushes.grow_youngtree2 = function(pos) abstract_bushes.grow_youngtree2 = function(pos)
local height = math.random(4,5) local height = math.random(4,5)
abstract_bushes.grow_youngtree_node2(pos,height) abstract_bushes.grow_youngtree_node2(pos,height)
end end
abstract_bushes.grow_youngtree_node2 = function(pos, height) abstract_bushes.grow_youngtree_node2 = function(pos, height)
local right_here = {x=pos.x, y=pos.y+1, z=pos.z} 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 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 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} 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, if minetest.get_node(right_here).name == "air" -- instead of check_air = true,
or minetest.get_node(right_here).name == "default:junglegrass" then or minetest.get_node(right_here).name == "default:junglegrass" then
if height == 4 then if height == 4 then
local two_above_right_here_south = {x=pos.x, y=pos.y+3, z=pos.z-1} 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} 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(right_here, {name="bushes:youngtree2_bottom"})
minetest.swap_node(above_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}) minetest.swap_node(two_above_right_here, {name="bushes:bushbranches2" , param2=2})
minetest.swap_node(two_above_right_here_south, {name="bushes:bushbranches2" , param2=0}) minetest.swap_node(two_above_right_here_south, {name="bushes:bushbranches2" , param2=0})
minetest.swap_node(three_above_right_here, {name="bushes:BushLeaves1" }) minetest.swap_node(three_above_right_here, {name="bushes:BushLeaves1" })
minetest.swap_node(three_above_right_here_south, {name="bushes:BushLeaves1" }) minetest.swap_node(three_above_right_here_south, {name="bushes:BushLeaves1" })
end end
end end
end end
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"stoneage:grass_with_silex", "stoneage:grass_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({rarity = bushes_youngtrees_rarity, rarity_fertility = bushes_youngtrees_rarity_fertility}),
min_elevation = 1, -- above sea level
}, },
max_count = 55, --10,15 "bushes:youngtrees",
rarity = 101 - 4, --3,4 abstract_bushes.grow_youngtree2
min_elevation = 1, -- above sea level
plantlife_limit = -0.9,
},
abstract_bushes.grow_youngtree2
) )
--http://dev.minetest.net/Node_Drawtypes

View File

@ -0,0 +1,10 @@
# 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 <EMAIL@ADDRESS>, YEAR.
Young Tree 2 (bottom)=Strauch 2 (Ansatz)
Bush Branches @1=Buschäste @1
Bush Leaves @1=Buschblätter @1

View File

@ -0,0 +1,10 @@
# 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

View File

@ -0,0 +1,11 @@
# 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 <fat115@framasoft.org>, 2017.
#
Young Tree 2 (bottom)=Arbuste 2 (bas)
Bush Branches @1=Branches de buisson @1
Bush Leaves @1=Feuilles de buisson @1

View File

@ -0,0 +1,10 @@
# 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 <EMAIL@ADDRESS>, YEAR.
Young Tree 2 (bottom)=
Bush Branches @1=
Bush Leaves @1=

3
bushes/mod.conf Normal file
View File

@ -0,0 +1,3 @@
name = bushes
depends = default, biome_lib
optional_depends = stoneage, sumpf

17
bushes/settingtypes.txt Normal file
View File

@ -0,0 +1,17 @@
#Bush rarity %
bushes_bush_rarity (Bush rarity %) float 99.9 0 100
#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

View File

@ -1,5 +1,5 @@
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("bushes_classic")
-- Basket -- Basket

View File

@ -1,4 +0,0 @@
biome_lib
plantlife_i18n
farming?
farming_plus?

View File

@ -4,7 +4,7 @@
bushes_classic = {} bushes_classic = {}
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("bushes_classic")
bushes_classic.bushes = { bushes_classic.bushes = {
"strawberry", "strawberry",
@ -30,7 +30,7 @@ local modpath = minetest.get_modpath('bushes_classic')
dofile(modpath..'/cooking.lua') dofile(modpath..'/cooking.lua')
dofile(modpath..'/nodes.lua') dofile(modpath..'/nodes.lua')
biome_lib:spawn_on_surfaces({ biome_lib.register_active_spawner({
spawn_delay = 3600, spawn_delay = 3600,
spawn_plants = bushes_classic.spawn_list, spawn_plants = bushes_classic.spawn_list,
avoid_radius = 10, avoid_radius = 10,
@ -55,4 +55,4 @@ biome_lib:spawn_on_surfaces({
minetest.register_alias("bushes:basket_pies", "bushes:basket_strawberry") minetest.register_alias("bushes:basket_pies", "bushes:basket_strawberry")
print(S("[Bushes] Loaded.")) print("[Bushes] Loaded.")

View File

@ -0,0 +1,46 @@
# 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
Strawberry Bush=Erdbeerbusch
Basket with Blackberry pies=Korb mit Brombeertorten
Blackberry=Brombeere
Blackberry Bush=Brombeerbusch
Cooked Blackberry pie=Brombeertorte
Raw Blackberry pie=Rohe Brombeertorte
Slice of Blackberry pie=Brombeertortenstueck
Basket with Blueberry pies=Korb mit Blaubeertorten
Blueberry=Blaubeere
Blueberry Bush=Blaubeerbusch
Cooked Blueberry pie=Blaubeertorte
Raw Blueberry pie=Rohe Blaubeertorte
Slice of Blueberry pie=Blaubeertortenstueck
Basket with Raspberry pies=Korb mit Himbeertorten
Cooked Raspberry pie=Himbeertorte
Raspberry=Himbeere
Raspberry Bush=Himbeerbusch
Raw Raspberry pie=Rohe Himbeertorte
Slice of Raspberry pie=Himbeertortenstueck
Basket with Gooseberry pies=Korb mit Stachelbeertorten
Cooked Gooseberry pie=Stachelbeertorte
Gooseberry=Stachelbeere
Gooseberry Bush=Stachelbeerbusch
Raw Gooseberry pie=Rohe 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
Mixed Berry=Beerenmix
Raw Mixed Berry pie=Rohe Beerenmixtorte
Slice of Mixed Berry pie=Beerenmixtortenstueck
Basket=Korb

View File

@ -0,0 +1,46 @@
# 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
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
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
Slice of Blueberry pie=Tranĉaĵo de Mirtelokuko
Basket with Raspberry pies=Korbo kun Frambokukoj
Cooked Raspberry pie=Kuirita Frambokuko
Raspberry=Frambo
Raspberry Bush=Framba Arbusto
Raw Raspberry pie=Kruda Frambokuko
Slice of Raspberry pie=Tranĉaĵo de Frambokuko
Basket with Gooseberry pies=Korbo kun Grosberkuko
Cooked Gooseberry pie=Kuirita Grosberkuko
Gooseberry=Grosbero
Gooseberry Bush=Grosberarbusto
Raw Gooseberry pie=Kruda 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
Mixed Berry=Miksita Bero
Raw Mixed Berry pie=Kruda Miksita Bera Kuko
Slice of Mixed Berry pie=Tranĉaĵo de Miksita Bera Kuko
Basket=Korbo

View File

@ -0,0 +1,46 @@
# 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 <carlosbarrazaes@gmail.com>, 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
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
Slice of Blackberry pie=Rebanada de Pastel de Mora
Basket with Blueberry pies=Cesta con Pasteles de Arándano
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
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
Raspberry=Frambuesa
Raspberry Bush=Arbusto de Frambuesa
Raw Raspberry pie=Pastel de Frambuesa Crudo
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
Gooseberry=Grosella
Gooseberry Bush=Arbusto de Grosella
Raw Gooseberry pie=Pastel de Grosella Crudo
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
Mixed Berry=Mezcla de Baya
Raw Mixed Berry pie=Pastel de Mezcla de Bayas Cruda
Slice of Mixed Berry pie=Rebanada de Pastel de Mezcla de Bayas
Basket=Cesta

View File

@ -0,0 +1,46 @@
# 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 <fat115@framasoft.org>, 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
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)
Slice of Blackberry pie=Part de tarte aux mûres
Basket with Blueberry pies=Panier de tartes aux mûres
Blueberry=Myrtilles
Blueberry Bush=Buisson de myrtilles
Cooked Blueberry pie=Tarte aux myrtilles (cuite)
Raw Blueberry pie=Tarte aux myrtilles (crue)
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)
Raspberry=Framboises
Raspberry Bush=Buisson de framboises
Raw Raspberry pie=Tarte aux framboises (crue)
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)
Gooseberry=Groseilles
Gooseberry Bush=Buisson de groseilles
Raw Gooseberry pie=Tarte aux groseilles (crue)
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
Mixed Berry=Fruits rouges
Raw Mixed Berry pie=Tarte aux fruits rouges (crue)
Slice of Mixed Berry pie=Part de tarte aux fruits rouges
Basket=Panier

View File

@ -0,0 +1,46 @@
# 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
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
Slice of Blackberry pie=Böğürtlenli pasta dilimi
Basket with Blueberry pies=Yaban mersini pastalı sepet
Blueberry=Yaban mersini
Blueberry Bush=Yaban mersini fidanı
Cooked Blueberry pie=Pişmiş yaban mersinli pasta
Raw Blueberry pie=Yaban mersinli çiğ pasta
Slice of Blueberry pie=Yaban mersinli pasta dilimi
Basket with Raspberry pies=Ahududulu pasta sepeti
Cooked Raspberry pie=Pişmiş ahududulu pasta
Raspberry=Ahududu
Raspberry Bush=Ahududu fidanı
Raw Raspberry pie=Ahududulu çiğ 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
Gooseberry=Bektaşi üzümü
Gooseberry Bush=Bektaşi üzümü fidanı
Raw Gooseberry pie=Bektaşi üzümlü çiğ 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
Mixed Berry=Dut
Raw Mixed Berry pie=Dutlu çiğ pasta
Slice of Mixed Berry pie=Dutlu pasta dilimi
Basket=Sepet

View File

@ -0,0 +1,46 @@
# 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 <EMAIL@ADDRESS>, YEAR.
#
Sugar=
Basket with Strawberry pies=
Cooked Strawberry pie=
Raw Strawberry pie=
Slice of Strawberry pie=
Strawberry=
Strawberry Bush=
Basket with Blackberry pies=
Blackberry=
Blackberry Bush=
Cooked Blackberry pie=
Raw Blackberry pie=
Slice of Blackberry pie=
Basket with Blueberry pies=
Blueberry=
Blueberry Bush=
Cooked Blueberry pie=
Raw Blueberry pie=
Slice of Blueberry pie=
Basket with Raspberry pies=
Cooked Raspberry pie=
Raspberry=
Raspberry Bush=
Raw Raspberry pie=
Slice of Raspberry pie=
Basket with Gooseberry pies=
Cooked Gooseberry pie=
Gooseberry=
Gooseberry Bush=
Raw Gooseberry pie=
Slice of Gooseberry pie=
Basket with Mixed Berry pies=
Cooked Mixed Berry pie=
Currently fruitless Bush=
Mixed Berry=
Raw Mixed Berry pie=
Slice of Mixed Berry pie=
Basket=

3
bushes_classic/mod.conf Normal file
View File

@ -0,0 +1,3 @@
name = bushes_classic
depends = biome_lib
optional_depends = farming, farming_plus

View File

@ -1,5 +1,5 @@
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("bushes_classic")
plantlife_bushes = {} plantlife_bushes = {}
@ -63,7 +63,7 @@ plantlife_bushes.after_dig_node = function(pos, oldnode, oldmetadata, digger)
-- with a chance of 1/3, return 2 bushes -- with a chance of 1/3, return 2 bushes
local amount local amount
if math.random(1,3) == 1 then if can_harvest and math.random(1,3) == 1 then
amount = "2" amount = "2"
else else
amount = "1" amount = "1"
@ -173,6 +173,13 @@ for i, bush_name in ipairs(bushes_classic.bushes) do
texture_top = "bushes_bush_top.png" texture_top = "bushes_bush_top.png"
texture_bottom = "bushes_bush_bottom.png" texture_bottom = "bushes_bush_bottom.png"
end end
local node_dig_prediction
local node_placement_prediction
if bush_name ~= "fruitless" then
node_dig_prediction = "bushes:fruitless_bush"
node_placement_prediction = "bushes:fruitless_bush"
end
minetest.register_node(":bushes:" .. bush_name .. "_bush", { minetest.register_node(":bushes:" .. bush_name .. "_bush", {
description = bushes_classic.bushes_descriptions[i][6], description = bushes_classic.bushes_descriptions[i][6],
@ -185,6 +192,8 @@ for i, bush_name in ipairs(bushes_classic.bushes) do
groups = groups, groups = groups,
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
drop = "", drop = "",
node_dig_prediction = node_dig_prediction,
node_placement_prediction = node_placement_prediction,
after_dig_node = function( pos, oldnode, oldmetadata, digger ) after_dig_node = function( pos, oldnode, oldmetadata, digger )
return plantlife_bushes.after_dig_node(pos, oldnode, oldmetadata, digger); return plantlife_bushes.after_dig_node(pos, oldnode, oldmetadata, digger);
end, end,

View File

@ -1,2 +0,0 @@
default
plantlife_i18n

View File

@ -5,7 +5,9 @@ local mname = "cavestuff"
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("cavestuff")
cavestuff = {}
dofile(minetest.get_modpath("cavestuff").."/nodes.lua") dofile(minetest.get_modpath("cavestuff").."/nodes.lua")
dofile(minetest.get_modpath("cavestuff").."/mapgen.lua") dofile(minetest.get_modpath("cavestuff").."/mapgen.lua")

View File

@ -0,0 +1,11 @@
# 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

View File

@ -0,0 +1,11 @@
# 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

View File

@ -0,0 +1,11 @@
# 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 <fat115@framasoft.org>, 2017.
#
Pebble=Caillou
Desert Pebble=Caillou du désert
Stalactite=Stalactite

View File

@ -0,0 +1,11 @@
# 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 <EMAIL@ADDRESS>, YEAR.
#
Pebble=
Desert Pebble=
Stalactite=

View File

@ -1,52 +1,65 @@
--Map Generation Stuff --Map Generation Stuff
minetest.register_on_generated(function(minp, maxp, seed) minetest.register_decoration({
if maxp.y >= 2 and minp.y <= 0 then decoration = {
-- Generate pebbles "cavestuff:pebble_1",
local perlin1 = minetest.get_perlin(329, 3, 0.6, 100) "cavestuff:pebble_2"
-- Assume X and Z lengths are equal },
local divlen = 16 place_on = {
local divs = (maxp.x-minp.x)/divlen+1; "default:dirt_with_grass",
for divx=0,divs-1 do "default:gravel",
for divz=0,divs-1 do "default:stone",
local x0 = minp.x + math.floor((divx+0)*divlen) "default:permafrost_with_stones"
local z0 = minp.z + math.floor((divz+0)*divlen) },
local x1 = minp.x + math.floor((divx+1)*divlen) noise_params = {
local z1 = minp.z + math.floor((divz+1)*divlen) offset = 0,
-- Determine pebble amount from perlin noise scale = 0.0078125,
local pebble_amount = math.floor(perlin1:get2d({x=x0, y=z0}) ^ 2 * 2) spread = {
-- Find random positions for pebbles based on this random y = 100,
local pr = PseudoRandom(seed+1) z = 100,
for i=0,pebble_amount do x = 100
local x = pr:next(x0, x1) },
local z = pr:next(z0, z1) seed = 0,
-- Find ground level (0...15) octaves = 3,
local ground_y = nil persist = 0.6,
for y=30,0,-1 do flags = "absvalue",
if minetest.get_node({x=x,y=y,z=z}).name ~= "air" then lacunarity = 2
ground_y = y },
break param2 = 0,
end flags = "all_floors",
end deco_type = "simple",
param2_max = 3,
y_min = -16,
y_max = 48
})
if ground_y then minetest.register_decoration({
local p = {x=x,y=ground_y+1,z=z} decoration = {
local nn = minetest.get_node(p).name "cavestuff:desert_pebble_1",
-- Check if the node can be replaced "cavestuff:desert_pebble_2"
if minetest.registered_nodes[nn] and },
minetest.registered_nodes[nn].buildable_to then place_on = {
nn = minetest.get_node({x=x,y=ground_y,z=z}).name "default:desert_sand",
-- If desert sand, add dry shrub "default:desert_stone"
if nn == "default:dirt_with_grass" then },
minetest.swap_node(p,{name="cavestuff:pebble_"..pr:next(1,2), param2=math.random(0,3)}) noise_params = {
elseif nn == "default:desert_sand" then offset = 0,
minetest.swap_node(p,{name="cavestuff:desert_pebble_"..pr:next(1,2), param2=math.random(0,3)}) scale = 0.0078125,
end spread = {
end y = 100,
end z = 100,
x = 100
end },
end seed = 0,
end octaves = 3,
end persist = 0.6,
end) flags = "absvalue",
lacunarity = 2
},
param2 = 0,
flags = "all_floors",
deco_type = "simple",
param2_max = 3,
y_min = -16,
y_max = 48
})

2
cavestuff/mod.conf Normal file
View File

@ -0,0 +1,2 @@
name = cavestuff
depends = default,biome_lib

View File

@ -1,5 +1,5 @@
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("cavestuff")
--Rocks --Rocks
@ -12,65 +12,65 @@ minetest.register_node("cavestuff:pebble_1",{
description = S("Pebble"), description = S("Pebble"),
drawtype = "mesh", drawtype = "mesh",
mesh = "cavestuff_pebble.obj", mesh = "cavestuff_pebble.obj",
tiles = {"undergrowth_pebble.png"}, tiles = {"undergrowth_pebble.png"},
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
groups = {cracky=3, stone=1}, groups = {cracky=3, stone=1, attached_node=1},
selection_box = cbox, selection_box = cbox,
collision_box = cbox, collision_box = cbox,
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
-- place a random pebble node -- place a random pebble node
local stack = ItemStack("cavestuff:pebble_"..math.random(1,2)) local stack = ItemStack("cavestuff:pebble_"..math.random(1,2))
local ret = minetest.item_place(stack, placer, pointed_thing) local ret = minetest.item_place(stack, placer, pointed_thing)
return ItemStack("cavestuff:pebble_1 "..itemstack:get_count()-(1-ret:get_count())) return ItemStack("cavestuff:pebble_1 "..itemstack:get_count()-(1-ret:get_count()))
end, end,
sounds = default.node_sound_stone_defaults(), sounds = default.node_sound_stone_defaults(),
}) })
minetest.register_node("cavestuff:pebble_2",{ minetest.register_node("cavestuff:pebble_2",{
drawtype = "mesh", drawtype = "mesh",
mesh = "cavestuff_pebble.obj", mesh = "cavestuff_pebble.obj",
tiles = {"undergrowth_pebble.png"}, tiles = {"undergrowth_pebble.png"},
drop = "cavestuff:pebble_1", drop = "cavestuff:pebble_1",
tiles = {"undergrowth_pebble.png"}, tiles = {"undergrowth_pebble.png"},
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
groups = {cracky=3, stone=1, not_in_creative_inventory=1}, groups = {cracky=3, stone=1, attached_node=1, not_in_creative_inventory=1},
selection_box = cbox, selection_box = cbox,
collision_box = cbox, collision_box = cbox,
sounds = default.node_sound_stone_defaults(), sounds = default.node_sound_stone_defaults(),
}) })
minetest.register_node("cavestuff:desert_pebble_1",{ minetest.register_node("cavestuff:desert_pebble_1",{
description = S("Desert Pebble"), description = S("Desert Pebble"),
drawtype = "mesh", drawtype = "mesh",
mesh = "cavestuff_pebble.obj", mesh = "cavestuff_pebble.obj",
tiles = {"default_desert_stone.png"}, tiles = {"default_desert_stone.png"},
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
groups = {cracky=3, stone=1}, groups = {cracky=3, stone=1, attached_node=1},
selection_box = cbox, selection_box = cbox,
collision_box = cbox, collision_box = cbox,
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
-- place a random pebble node -- place a random pebble node
local stack = ItemStack("cavestuff:desert_pebble_"..math.random(1,2)) local stack = ItemStack("cavestuff:desert_pebble_"..math.random(1,2))
local ret = minetest.item_place(stack, placer, pointed_thing) local ret = minetest.item_place(stack, placer, pointed_thing)
return ItemStack("cavestuff:desert_pebble_1 "..itemstack:get_count()-(1-ret:get_count())) return ItemStack("cavestuff:desert_pebble_1 "..itemstack:get_count()-(1-ret:get_count()))
end, end,
sounds = default.node_sound_stone_defaults(), sounds = default.node_sound_stone_defaults(),
}) })
minetest.register_node("cavestuff:desert_pebble_2",{ minetest.register_node("cavestuff:desert_pebble_2",{
drawtype = "mesh", drawtype = "mesh",
mesh = "cavestuff_pebble.obj", mesh = "cavestuff_pebble.obj",
drop = "cavestuff:desert_pebble_1", drop = "cavestuff:desert_pebble_1",
tiles = {"default_desert_stone.png"}, tiles = {"default_desert_stone.png"},
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
groups = {cracky=3, stone=1, not_in_creative_inventory=1}, groups = {cracky=3, stone=1, attached_node=1, not_in_creative_inventory=1},
selection_box = cbox, selection_box = cbox,
collision_box = cbox, collision_box = cbox,
sounds = default.node_sound_stone_defaults(), sounds = default.node_sound_stone_defaults(),
}) })
--Staclactites --Staclactites
@ -85,19 +85,34 @@ minetest.register_node("cavestuff:stalactite_1",{
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
{-0.187500,0.425000,-0.150003,0.162500,0.500000,0.162500}, {-0.187500,-0.425000,-0.150003,0.162500,-0.500000,0.162500},
{-0.112500,0.162500,-0.100000,0.087500,0.475000,0.087500}, {-0.112500,-0.162500,-0.100000,0.087500,-0.475000,0.087500},
{-0.062500,-0.275000,-0.062500,0.062500,0.500000,0.062500}, {-0.062500,0.275000,-0.062500,0.062500,-0.500000,0.062500},
{-0.037500,-0.837500,0.037500,0.037500,0.500000,-0.025000}, {-0.037500,0.837500,0.037500,0.037500,-0.500000,-0.025000},
} }
}, },
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
local pt = pointed_thing local dir = vector.subtract(pointed_thing.above, pointed_thing.under)
if minetest.get_node(pt.under).name=="default:stone" local base = pointed_thing.under
and minetest.get_node({x=pt.under.x, y=pt.under.y-1, z=pt.under.z}).name=="air" local place = vector.add(base, dir)
and minetest.get_node({x=pt.under.x, y=pt.under.y-2, z=pt.under.z}).name=="air" then local above = vector.add(place, dir)
minetest.swap_node({x=pt.under.x, y=pt.under.y-1, z=pt.under.z}, {name="cavestuff:stalactite_"..math.random(1,3)})
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
minetest.record_protection_violation(place, playername)
return
end
if minetest.get_node(base).name == "default:stone"
and minetest.get_node(place).name == "air"
and minetest.get_node(above).name == "air"
then
minetest.swap_node(place, {
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.setting_getbool("creative_mode") then
itemstack:take_item() itemstack:take_item()
end end
@ -116,10 +131,10 @@ minetest.register_node("cavestuff:stalactite_2",{
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
{-0.187500,0.387500,-0.150003,0.162500,0.500000,0.162500}, {-0.187500,-0.387500,-0.150003,0.162500,-0.500000,0.162500},
{-0.112500,0.112500,-0.100000,0.087500,0.475000,0.087500}, {-0.112500,-0.112500,-0.100000,0.087500,-0.475000,0.087500},
{-0.062500,-0.675000,-0.062500,0.062500,0.500000,0.062500}, {-0.062500,0.675000,-0.062500,0.062500,-0.500000,0.062500},
{-0.037500,-0.975000,0.037500,0.037500,0.500000,-0.025000}, {-0.037500,0.975000,0.037500,0.037500,-0.500000,-0.025000},
} }
}, },
}) })
@ -132,14 +147,14 @@ minetest.register_node("cavestuff:stalactite_3",{
paramtype = "light", paramtype = "light",
paramtype2 = "wallmounted", paramtype2 = "wallmounted",
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = { fixed = {
{-0.187500,0.387500,-0.150003,0.162500,0.500000,0.162500}, {-0.187500,-0.387500,-0.150003,0.162500,-0.500000,0.162500},
{-0.112500,0.037500,-0.100000,0.087500,0.475000,0.087500}, {-0.112500,-0.037500,-0.100000,0.087500,-0.475000,0.087500},
{-0.062500,-0.437500,-0.062500,0.062500,0.500000,0.062500}, {-0.062500,0.437500,-0.062500,0.062500,-0.500000,0.062500},
{-0.037500,-1.237500,0.037500,0.037500,0.500000,-0.025000}, {-0.037500,1.237500,0.037500,0.037500,-0.500000,-0.025000},
} }
}, },
}) })
--Stalagmites --Stalagmites

View File

@ -1,4 +0,0 @@
default
biome_lib
plantlife_i18n
farming?

View File

@ -14,7 +14,7 @@ local mname = "dryplants"
abstract_dryplants = {} abstract_dryplants = {}
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("dryplants")
dofile(minetest.get_modpath("dryplants").."/crafting.lua") dofile(minetest.get_modpath("dryplants").."/crafting.lua")
dofile(minetest.get_modpath("dryplants").."/settings.txt") dofile(minetest.get_modpath("dryplants").."/settings.txt")
@ -130,6 +130,7 @@ minetest.register_node("dryplants:grass", {
paramtype = "light", paramtype = "light",
sunlight_propagates = true, sunlight_propagates = true,
tiles = {"dryplants_grass.png"}, tiles = {"dryplants_grass.png"},
use_texture_alpha = "clip",
drawtype = "nodebox", drawtype = "nodebox",
node_box = { node_box = {
type = "fixed", type = "fixed",
@ -161,6 +162,7 @@ minetest.register_node("dryplants:hay", {
paramtype = "light", paramtype = "light",
sunlight_propagates = true, sunlight_propagates = true,
tiles = {"dryplants_hay.png"}, tiles = {"dryplants_hay.png"},
use_texture_alpha = "clip",
drawtype = "nodebox", drawtype = "nodebox",
node_box = { node_box = {
type = "fixed", type = "fixed",

View File

@ -9,7 +9,7 @@
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("dryplants")
abstract_dryplants.grow_juncus = function(pos) abstract_dryplants.grow_juncus = function(pos)
local juncus_type = math.random(2,3) local juncus_type = math.random(2,3)
@ -92,44 +92,42 @@ minetest.register_node("dryplants:juncus_02", {
-- GENERATE SMALL JUNCUS -- GENERATE SMALL JUNCUS
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- near water or swamp -- near water or swamp
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
--"default:desert_sand", --"default:desert_sand",
--"default:sand", --"default:sand",
"stoneage:grass_with_silex", "stoneage:grass_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({max_count = JUNCUS_NEAR_WATER_PER_MAPBLOCK, rarity = 101 - JUNCUS_NEAR_WATER_RARITY}),
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,
}, },
max_count = JUNCUS_NEAR_WATER_PER_MAPBLOCK, "dryplants:juncus_near_water",
rarity = 101 - JUNCUS_NEAR_WATER_RARITY, abstract_dryplants.grow_juncus
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 -- at dunes/beach
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
--"default:dirt_with_grass", --"default:dirt_with_grass",
--"default:desert_sand", --"default:desert_sand",
"default:sand", "default:sand",
--"stoneage:grass_with_silex", --"stoneage:grass_with_silex",
--"sumpf:peat", --"sumpf:peat",
--"sumpf:sumpf" --"sumpf:sumpf"
},
noise_params = pl.generate_noise_params({max_count = JUNCUS_AT_BEACH_PER_MAPBLOCK, rarity = 101 - JUNCUS_AT_BEACH_RARITY}),
min_elevation = 1, -- above sea level
near_nodes = {"default:dirt_with_grass"},
near_nodes_size = 2,
near_nodes_vertical = 1,
near_nodes_count = 1,
}, },
max_count = JUNCUS_AT_BEACH_PER_MAPBLOCK, "dryplants:junces_at_beach",
rarity = 101 - JUNCUS_AT_BEACH_RARITY, abstract_dryplants.grow_juncus
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
) )

View File

@ -0,0 +1,28 @@
# 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
Short Grass=Kurzes Gras
Juncus=Binsen
Wet Reed=Nasses Schilf
Wet Reed Slab=Nasse Schilfstufe
Wet Reed Roof=Nasses Schilfdach
Wet Reed Roof Corner=Nasser Schilfdachwinkel
Wet Reed Roof Corner 2=Nasser Schilfdachwinkel 2
Reed=Schilf
Reed Slab=Schilfstufe
Reed Roof=Schilfdach
Reed Roof Corner=Schilfdachwinkel
Reed Roof Corner 2=Schilfdachwinkel
Reedmace=Rohrkolben
Reedmace, height: 1=Rohrkolben, Höhe: 1
Reedmace, height: 2=Rohrkolben, Höhe: 2
Reedmace, height: 3=Rohrkolben, Höhe: 3
Reedmace, height: 3 & Spikes=Rohrkolben, Höhe: 3 & Rispe

View File

@ -0,0 +1,28 @@
# 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
Short Grass=Mallonga Herbo
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 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 2=Tegmentangulo 2 de Kano
Reedmace=Tifeo
Reedmace, height: 1=Tifeo, alteco: 1
Reedmace, height: 2=Tifeo, alteco: 2
Reedmace, height: 3=Tifeo, alteco: 3
Reedmace, height: 3 & Spikes=Tifeo, alteco: 3 & Pikiloj

View File

@ -0,0 +1,28 @@
# 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 <fat115@framasoft.org>, 2017.
#
Sickle=Faucille
Cut Grass=Herbe coupée
Hay=Foin
Short Grass=Herbes courtes
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 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 2=Angle de toit en roseau 2
Reedmace=Roseau
Reedmace, height: 1=Roseau, 1 de hauteur
Reedmace, height: 2=Roseau, 2 de hauteur
Reedmace, height: 3=Roseau, 3 de hauteur
Reedmace, height: 3 & Spikes=Roseau, 3 de hauteur avec panicules

View File

@ -0,0 +1,28 @@
# 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 <EMAIL@ADDRESS>, YEAR.
#
Sickle=
Cut Grass=
Hay=
Short Grass=
Juncus=
Wet Reed=
Wet Reed Slab=
Wet Reed Roof=
Wet Reed Roof Corner=
Wet Reed Roof Corner 2=
Reed=
Reed Slab=
Reed Roof=
Reed Roof Corner=
Reed Roof Corner 2=
Reedmace=
Reedmace, height: 1=
Reedmace, height: 2=
Reedmace, height: 3=
Reedmace, height: 3 & Spikes=

View File

@ -12,14 +12,13 @@ abstract_dryplants.grow_grass_variation = function(pos)
minetest.swap_node(right_here, {name="dryplants:grass_short"}) minetest.swap_node(right_here, {name="dryplants:grass_short"})
end end
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
}, },
max_count = 4800, noise_params = pl.generate_noise_params({max_count = 4800, rarity = 25}),
rarity = 25,
min_elevation = 1, -- above sea level min_elevation = 1, -- above sea level
plantlife_limit = -0.9,
}, },
"dryplants:grass",
abstract_dryplants.grow_grass_variation abstract_dryplants.grow_grass_variation
) )

3
dryplants/mod.conf Normal file
View File

@ -0,0 +1,3 @@
name = dryplants
depends = default, biome_lib
optional_depends = farming

View File

@ -7,26 +7,23 @@
-- Looked at code from: default -- Looked at code from: default
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
abstract_dryplants.grow_grass = function(pos) minetest.register_decoration({
local right_here = {x=pos.x, y=pos.y+1, z=pos.z} decoration = {
local grass_size = math.random(1,5) "default:grass_1",
if minetest.get_node(right_here).name == "air" -- instead of check_air = true, "default:grass_2",
or minetest.get_node(right_here).name == "default:junglegrass" then "default:grass_3",
minetest.swap_node(right_here, {name="default:grass_"..grass_size}) "default:grass_4",
end "default:grass_5"
end },
place_on = {
biome_lib:register_generate_plant({
surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"stoneage:grass_with_silex", "stoneage:grass_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
}, },
max_count = TALL_GRASS_PER_MAPBLOCK, noise_params = pl.generate_noise_params({max_count = TALL_GRASS_PER_MAPBLOCK, rarity = 101 - TALL_GRASS_RARITY}),
rarity = 101 - TALL_GRASS_RARITY, flags = "all_floors",
min_elevation = 1, -- above sea level deco_type = "simple",
plantlife_limit = -0.9, y_min = 1,
}, y_max = 48
abstract_dryplants.grow_grass })
)

View File

@ -6,7 +6,7 @@
-- Dependencies: default -- Dependencies: default
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("dryplants")
minetest.register_alias("stairs:stair_wetreed", "dryplants:wetreed_roof") minetest.register_alias("stairs:stair_wetreed", "dryplants:wetreed_roof")
minetest.register_alias("stairs:slab_wetreed", "dryplants:wetreed_slab") minetest.register_alias("stairs:slab_wetreed", "dryplants:wetreed_slab")

View File

@ -18,7 +18,7 @@
-- The seed hairs were used by some Native American groups as tinder for starting fires -- The seed hairs were used by some Native American groups as tinder for starting fires
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("dryplants")
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- REEDMACE SHAPES -- REEDMACE SHAPES
@ -264,7 +264,8 @@ minetest.register_node("dryplants:reedmace_sapling", {
groups = { groups = {
snappy=3, snappy=3,
flammable=2, flammable=2,
attached_node=1 attached_node=1,
sapling=1,
}, },
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
selection_box = { selection_box = {
@ -327,7 +328,7 @@ minetest.register_entity("dryplants:reedmace_water_entity",{
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- SPAWN REEDMACE -- SPAWN REEDMACE
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
--[[biome_lib:spawn_on_surfaces({ --[[biome_lib.register_active_spawner({
spawn_delay = 1200, spawn_delay = 1200,
spawn_plants = {"dryplants:reedmace_sapling"}, spawn_plants = {"dryplants:reedmace_sapling"},
spawn_chance = 400, spawn_chance = 400,
@ -348,66 +349,63 @@ minetest.register_entity("dryplants:reedmace_water_entity",{
-- GENERATE REEDMACE -- GENERATE REEDMACE
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- near water or swamp -- near water or swamp
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:desert_sand", "default:desert_sand",
"stoneage:grass_with_silex", "stoneage:grass_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({max_count = REEDMACE_NEAR_WATER_PER_MAPBLOCK, rarity = 101 - REEDMACE_NEAR_WATER_RARITY}),
--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,
}, },
max_count = REEDMACE_NEAR_WATER_PER_MAPBLOCK, "dryplants:reedmace_near_water",
rarity = 101 - REEDMACE_NEAR_WATER_RARITY, abstract_dryplants.grow_reedmace
--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
) )
-- in water -- in water
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:dirt", "default:dirt",
"default:dirt_with_grass", "default:dirt_with_grass",
--"default:desert_sand", --"default:desert_sand",
--"stoneage:grass_with_silex", --"stoneage:grass_with_silex",
"stoneage:sand_with_silex", "stoneage:sand_with_silex",
"sumpf:peat", "sumpf:peat",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({max_count = REEDMACE_IN_WATER_PER_MAPBLOCK, rarity = 101 - REEDMACE_IN_WATER_RARITY}),
--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,
}, },
max_count = REEDMACE_IN_WATER_PER_MAPBLOCK, "dryplants:reedmace_in_water",
rarity = 101 - REEDMACE_IN_WATER_RARITY, abstract_dryplants.grow_reedmace_water
--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
) )
-- for oases & tropical beaches & tropical swamps -- for oases & tropical beaches & tropical swamps
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = { surface = {
"default:sand", "default:sand",
"sumpf:sumpf" "sumpf:sumpf"
},
noise_params = pl.generate_noise_params({max_count = REEDMACE_FOR_OASES_PER_MAPBLOCK, 101 - REEDMACE_FOR_OASES_RARITY}),
--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,
}, },
max_count = REEDMACE_FOR_OASES_PER_MAPBLOCK, "dryplants:reemace_oases",
rarity = 101 - REEDMACE_FOR_OASES_RARITY, abstract_dryplants.grow_reedmace
--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
) )

View File

@ -1,5 +1,5 @@
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- Ferns - Crafting 0.0.5 -- Ferns - Crafting 0.0.5
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------

View File

@ -1,3 +0,0 @@
default
biome_lib
plantlife_i18n

View File

@ -15,7 +15,7 @@
assert(abstract_ferns.config.enable_lady_fern == true) assert(abstract_ferns.config.enable_lady_fern == true)
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
-- Maintain backward compatibilty -- Maintain backward compatibilty
-- minetest-0.5: Begin -- minetest-0.5: Begin
@ -87,7 +87,7 @@ end
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
if abstract_ferns.config.lady_ferns_near_tree == true then if abstract_ferns.config.lady_ferns_near_tree == true then
biome_lib:register_generate_plant({ -- near trees (woodlands) biome_lib.register_on_generate({ -- near trees (woodlands)
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:mossycobble", "default:mossycobble",
@ -116,7 +116,7 @@ if abstract_ferns.config.lady_ferns_near_tree == true then
end end
if abstract_ferns.config.lady_ferns_near_rock == true then if abstract_ferns.config.lady_ferns_near_rock == true then
biome_lib:register_generate_plant({ -- near stone (mountains) biome_lib.register_on_generate({ -- near stone (mountains)
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:mossycobble", "default:mossycobble",
@ -143,7 +143,7 @@ if abstract_ferns.config.lady_ferns_near_rock == true then
end end
if abstract_ferns.config.lady_ferns_near_ores == true then -- this one causes a huge fps drop if abstract_ferns.config.lady_ferns_near_ores == true then -- this one causes a huge fps drop
biome_lib:register_generate_plant({ -- near ores (potential mining sites) biome_lib.register_on_generate({ -- near ores (potential mining sites)
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:mossycobble", "default:mossycobble",
@ -183,7 +183,7 @@ if abstract_ferns.config.lady_ferns_near_ores == true then -- this one causes a
end end
if abstract_ferns.config.lady_ferns_in_groups == true then -- this one is meant as a replacement of Ferns_near_Ores if abstract_ferns.config.lady_ferns_in_groups == true then -- this one is meant as a replacement of Ferns_near_Ores
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:mossycobble", "default:mossycobble",

View File

@ -10,9 +10,28 @@
assert(abstract_ferns.config.enable_giant_treefern == true) assert(abstract_ferns.config.enable_giant_treefern == true)
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
-- lot of code, lot to load -- lot of code, lot to load
function abstract_ferns.can_grow_giant_tree_fern(pos)
local node_name = minetest.get_node(pos).name
if node_name ~= "air" and node_name ~= "ferns:sapling_giant_tree_fern" and node_name ~= "default:junglegrass" then
return false
end
local below_name = minetest.get_node(vector.new(pos.x, pos.y - 1, pos.z)).name
if minetest.get_item_group(below_name, "soil") == 0 and minetest.get_item_group(below_name, "sand") == 0 then
return false
end
local light = minetest.get_node_light(pos, 0.5)
if light <= 8 then
return false
end
return true
end
abstract_ferns.grow_giant_tree_fern = function(pos) abstract_ferns.grow_giant_tree_fern = function(pos)
local pos_aux = {x = pos.x, y = pos.y + 1, z = pos.z} local pos_aux = {x = pos.x, y = pos.y + 1, z = pos.z}
local name = minetest.get_node(pos_aux).name local name = minetest.get_node(pos_aux).name
@ -162,6 +181,14 @@ minetest.register_node("ferns:tree_fern_leave_big", {
}, },
drop = "", drop = "",
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
after_destruct = function(pos,oldnode)
for _, d in pairs({{x=-1,z=0},{x=1,z=0},{x=0,z=-1},{x=0,z=1}}) do
local node = minetest.get_node({x=pos.x+d.x,y=pos.y+1,z=pos.z+d.z})
if node.name == "ferns:tree_fern_leave_big" then
minetest.dig_node({x=pos.x+d.x,y=pos.y+1,z=pos.z+d.z})
end
end
end,
}) })
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
@ -173,6 +200,7 @@ minetest.register_node("ferns:tree_fern_leave_big_end", {
paramtype = "light", paramtype = "light",
paramtype2 = "facedir", paramtype2 = "facedir",
tiles = { "ferns_tree_fern_leave_big_end.png" }, tiles = { "ferns_tree_fern_leave_big_end.png" },
use_texture_alpha = "clip",
walkable = false, walkable = false,
node_box = { node_box = {
type = "fixed", type = "fixed",
@ -205,6 +233,7 @@ minetest.register_node("ferns:fern_trunk_big_top", {
"ferns_fern_trunk_big_top.png^ferns_tree_fern_leave_big_cross.png", "ferns_fern_trunk_big_top.png^ferns_tree_fern_leave_big_cross.png",
"ferns_fern_trunk_big.png" "ferns_fern_trunk_big.png"
}, },
use_texture_alpha = "clip",
node_box = { node_box = {
type = "fixed", type = "fixed",
-- {left, bottom, front, right, top, back } -- {left, bottom, front, right, top, back }
@ -242,6 +271,7 @@ minetest.register_node("ferns:fern_trunk_big", {
"ferns_fern_trunk_big_top.png", "ferns_fern_trunk_big_top.png",
"ferns_fern_trunk_big.png" "ferns_fern_trunk_big.png"
}, },
use_texture_alpha = "clip",
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = {-1/4, -1/2, -1/4, 1/4, 1/2, 1/4}, fixed = {-1/4, -1/2, -1/4, 1/4, 1/2, 1/4},
@ -271,7 +301,7 @@ minetest.register_node("ferns:sapling_giant_tree_fern", {
tiles = {"ferns_sapling_tree_fern_giant.png"}, tiles = {"ferns_sapling_tree_fern_giant.png"},
inventory_image = "ferns_sapling_tree_fern_giant.png", inventory_image = "ferns_sapling_tree_fern_giant.png",
walkable = false, walkable = false,
groups = {snappy=3,flammable=2,flora=1,attached_node=1}, groups = {snappy=3,flammable=2,flora=1,attached_node=1,sapling=1},
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
selection_box = { selection_box = {
type = "fixed", type = "fixed",
@ -285,7 +315,9 @@ minetest.register_abm({
interval = 1000, interval = 1000,
chance = 4, chance = 4,
action = function(pos, node, _, _) action = function(pos, node, _, _)
abstract_ferns.grow_giant_tree_fern({x = pos.x, y = pos.y-1, z = pos.z}) if abstract_ferns.can_grow_giant_tree_fern(pos) then
abstract_ferns.grow_giant_tree_fern({x = pos.x, y = pos.y-1, z = pos.z})
end
end end
}) })
@ -295,7 +327,7 @@ minetest.register_abm({
-- in jungles -- in jungles
if abstract_ferns.config.enable_giant_treeferns_in_jungle == true then if abstract_ferns.config.enable_giant_treeferns_in_jungle == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:dirt_with_rainforest_litter", -- minetest >= 0.4.16 "default:dirt_with_rainforest_litter", -- minetest >= 0.4.16
@ -321,7 +353,7 @@ end
-- for oases & tropical beaches -- for oases & tropical beaches
if abstract_ferns.config.enable_giant_treeferns_in_oases == true then if abstract_ferns.config.enable_giant_treeferns_in_oases == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:sand"--, "default:sand"--,
--"default:desert_sand" --"default:desert_sand"

View File

@ -11,7 +11,7 @@
assert(abstract_ferns.config.enable_horsetails == true) assert(abstract_ferns.config.enable_horsetails == true)
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- HORSETAIL (EQUISETUM) -- HORSETAIL (EQUISETUM)
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
@ -75,7 +75,7 @@ create_nodes()
-- Spawning -- Spawning
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
if abstract_ferns.config.enable_horsetails_spawning == true then if abstract_ferns.config.enable_horsetails_spawning == true then
biome_lib:spawn_on_surfaces({ biome_lib.register_active_spawner({
spawn_delay = 1200, spawn_delay = 1200,
spawn_plants = node_names, spawn_plants = node_names,
spawn_chance = 400, spawn_chance = 400,
@ -104,7 +104,7 @@ end
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
if abstract_ferns.config.enable_horsetails_on_grass == true then if abstract_ferns.config.enable_horsetails_on_grass == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:dirt_with_coniferous_litter", -- minetest >= 0.5 "default:dirt_with_coniferous_litter", -- minetest >= 0.5
@ -137,7 +137,7 @@ if abstract_ferns.config.enable_horsetails_on_grass == true then
end end
if abstract_ferns.config.enable_horsetails_on_stones == true then if abstract_ferns.config.enable_horsetails_on_stones == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:gravel", -- roots go deep "default:gravel", -- roots go deep
"default:mossycobble", "default:mossycobble",

View File

@ -9,7 +9,7 @@ local mname = "ferns" -- former "archaeplantae"
abstract_ferns = {} abstract_ferns = {}
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
dofile(minetest.get_modpath("ferns").."/settings.lua") dofile(minetest.get_modpath("ferns").."/settings.lua")

23
ferns/locale/ferns.de.tr Normal file
View File

@ -0,0 +1,23 @@
# 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
Giant Tree Fern Sapling=Riesiger Baumfarnsetzling
Young Horsetail (Equisetum)=Junger Schachtelhalm (Equisetum)
Horsetail (Equisetum)=Schachtelhalm (Equisetum)
Fern Trunk (Dicksonia)=Farnstamm (Dicksonia)
Tree Fern Sapling (Dicksonia)=Baumfarnsetzling (Dicksonia)

23
ferns/locale/ferns.eo.tr Normal file
View File

@ -0,0 +1,23 @@
# 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
Giant Tree Fern Sapling=Arbido de Giganta Arba Filiko
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)

22
ferns/locale/ferns.fr.tr Normal file
View File

@ -0,0 +1,22 @@
# 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 <fat115@framasoft.org>, 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
Giant Tree Fern Sapling=Pousse de fougère géante
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)

23
ferns/locale/template.txt Normal file
View File

@ -0,0 +1,23 @@
# 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 <EMAIL@ADDRESS>, 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=
Giant Tree Fern Sapling=
Young Horsetail (Equisetum)=
Horsetail (Equisetum)=
Fern Trunk (Dicksonia)=
Tree Fern Sapling (Dicksonia)=

2
ferns/mod.conf Normal file
View File

@ -0,0 +1,2 @@
name = ferns
depends = default, biome_lib

View File

@ -7,10 +7,29 @@
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("ferns")
assert(abstract_ferns.config.enable_treefern == true) assert(abstract_ferns.config.enable_treefern == true)
function abstract_ferns.can_grow_tree_fern(pos)
local node_name = minetest.get_node(pos).name
if node_name ~= "air" and node_name ~= "ferns:sapling_tree_fern" and node_name ~= "default:junglegrass" then
return false
end
local below_name = minetest.get_node(vector.new(pos.x, pos.y - 1, pos.z)).name
if minetest.get_item_group(below_name, "soil") == 0 and minetest.get_item_group(below_name, "sand") == 0 then
return false
end
local light = minetest.get_node_light(pos, 0.5)
if light <= 8 then
return false
end
return true
end
abstract_ferns.grow_tree_fern = function(pos) abstract_ferns.grow_tree_fern = function(pos)
local pos_aux = {x = pos.x, y = pos.y + 1, z = pos.z} local pos_aux = {x = pos.x, y = pos.y + 1, z = pos.z}
@ -128,6 +147,7 @@ minetest.register_node("ferns:fern_trunk", {
"ferns_fern_trunk_top.png", "ferns_fern_trunk_top.png",
"ferns_fern_trunk.png" "ferns_fern_trunk.png"
}, },
use_texture_alpha = "clip",
node_box = { node_box = {
type = "fixed", type = "fixed",
fixed = {-1/8, -1/2, -1/8, 1/8, 1/2, 1/8}, fixed = {-1/8, -1/2, -1/8, 1/8, 1/2, 1/8},
@ -158,7 +178,7 @@ minetest.register_node("ferns:sapling_tree_fern", {
tiles = {"ferns_sapling_tree_fern.png"}, tiles = {"ferns_sapling_tree_fern.png"},
inventory_image = "ferns_sapling_tree_fern.png", inventory_image = "ferns_sapling_tree_fern.png",
walkable = false, walkable = false,
groups = {snappy=3,flammable=2,flora=1,attached_node=1}, groups = {snappy=3,flammable=2,flora=1,attached_node=1,sapling=1},
sounds = default.node_sound_leaves_defaults(), sounds = default.node_sound_leaves_defaults(),
selection_box = { selection_box = {
type = "fixed", type = "fixed",
@ -171,7 +191,9 @@ minetest.register_abm({
interval = 1000, interval = 1000,
chance = 4, chance = 4,
action = function(pos, node, _, _) action = function(pos, node, _, _)
abstract_ferns.grow_tree_fern({x = pos.x, y = pos.y-1, z = pos.z}) if abstract_ferns.can_grow_tree_fern(pos) then
abstract_ferns.grow_tree_fern({x = pos.x, y = pos.y-1, z = pos.z})
end
end end
}) })
@ -181,7 +203,7 @@ minetest.register_abm({
-- in jungles -- in jungles
if abstract_ferns.config.enable_treeferns_in_jungle == true then if abstract_ferns.config.enable_treeferns_in_jungle == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:dirt_with_grass", "default:dirt_with_grass",
"default:dirt_with_rainforest_litter", -- minetest >= 0.4.16 "default:dirt_with_rainforest_litter", -- minetest >= 0.4.16
@ -210,7 +232,7 @@ end
-- for oases & tropical beaches -- for oases & tropical beaches
if abstract_ferns.config.enable_treeferns_in_oases == true then if abstract_ferns.config.enable_treeferns_in_oases == true then
biome_lib:register_generate_plant({ biome_lib.register_on_generate({
surface = { surface = {
"default:sand"--, "default:sand"--,
--"default:desert_sand" --"default:desert_sand"

View File

@ -1,4 +0,0 @@
biome_lib
plantlife_i18n
farming?
flowers?

View File

@ -1,24 +0,0 @@
Changelog
---------
2012-08-06: Tweaked selection boxes on all nodes. Tweaked seaweed to use
signlike instead of raillike drawtype, (still forced to only spawn flat as
usual). Adjusted light level limits to give it more time to grow. Created
this changelog file using github commit messages as the basis. Shrunk the
geranium flower down a bit to better match the others.
2012-08-03: Tuned out the random-numbers-inside-ABM stuff. Uses the ABM's
chance setting instead. Should be approximately the same as before, but
hopefully using a tad less CPU. Minor tweak to ABM interval/growing delay.
2012-08-01: Added blue geranium to the collection of flowers.
2012-07-31: Disable debug by default.
2012-07-30: many updates over the course of the day - first commit, removed
some redundant files, added wield/inventory image entries for each item, to
force the game to draw them properly (these shouldn't be needed, must be a
bug). Tweaked spawn code so that the radius check also includes the name of
the item being spawned as well as items in group:flower, that way all items can
have a radius test, and not just those in group:flower. Fiddled with the spawn
rates a bit.

View File

@ -1,481 +0,0 @@
-- support for i18n
local S = plantlife_i18n.gettext
-- This file supplies a few additional plants and some related crafts
-- for the plantlife modpack. Last revision: 2013-04-24
flowers_plus = {}
local SPAWN_DELAY = 1000
local SPAWN_CHANCE = 200
local flowers_seed_diff = 329
local lilies_max_count = 320
local lilies_rarity = 33
local seaweed_max_count = 320
local seaweed_rarity = 33
local sunflowers_max_count = 10
local sunflowers_rarity = 25
-- register the various rotations of waterlilies
local lilies_list = {
{ nil , nil , 1 },
{ "225", "22.5" , 2 },
{ "45" , "45" , 3 },
{ "675", "67.5" , 4 },
{ "s1" , "small_1" , 5 },
{ "s2" , "small_2" , 6 },
{ "s3" , "small_3" , 7 },
{ "s4" , "small_4" , 8 },
}
for i in ipairs(lilies_list) do
local deg1 = ""
local deg2 = ""
local lily_groups = {snappy = 3,flammable=2,flower=1}
if lilies_list[i][1] ~= nil then
deg1 = "_"..lilies_list[i][1]
deg2 = "_"..lilies_list[i][2]
lily_groups = { snappy = 3,flammable=2,flower=1, not_in_creative_inventory=1 }
end
minetest.register_node(":flowers:waterlily"..deg1, {
description = S("Waterlily"),
drawtype = "nodebox",
tiles = {
"flowers_waterlily"..deg2..".png",
"flowers_waterlily"..deg2..".png^[transformFY"
},
inventory_image = "flowers_waterlily.png",
wield_image = "flowers_waterlily.png",
sunlight_propagates = true,
paramtype = "light",
paramtype2 = "facedir",
walkable = false,
groups = lily_groups,
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = { -0.4, -0.5, -0.4, 0.4, -0.45, 0.4 },
},
node_box = {
type = "fixed",
fixed = { -0.5, -0.49, -0.5, 0.5, -0.49, 0.5 },
},
buildable_to = true,
node_placement_prediction = "",
liquids_pointable = true,
drop = "flowers:waterlily",
on_place = function(itemstack, placer, pointed_thing)
local keys=placer:get_player_control()
local pt = pointed_thing
local place_pos = nil
local top_pos = {x=pt.under.x, y=pt.under.y+1, z=pt.under.z}
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 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
place_pos = top_pos
else
return
end
elseif biome_lib:get_nodedef_field(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 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"
elseif waterlily == 2 then
nodename = "flowers:waterlily_225"
elseif waterlily == 3 then
nodename = "flowers:waterlily_45"
elseif waterlily == 4 then
nodename = "flowers:waterlily_675"
elseif waterlily == 5 then
nodename = "flowers:waterlily_s1"
elseif waterlily == 6 then
nodename = "flowers:waterlily_s2"
elseif waterlily == 7 then
nodename = "flowers:waterlily_s3"
elseif waterlily == 8 then
nodename = "flowers:waterlily_s4"
end
minetest.swap_node(place_pos, {name = nodename, param2 = math.random(0,3) })
else
local fdir = minetest.dir_to_facedir(placer:get_look_dir())
minetest.swap_node(place_pos, {name = "flowers:waterlily", param2 = fdir})
end
if not biome_lib.expect_infinite_stacks then
itemstack:take_item()
end
return itemstack
end
end,
})
end
local algae_list = { {nil}, {2}, {3}, {4} }
for i in ipairs(algae_list) do
local num = ""
local algae_groups = {snappy = 3,flammable=2,flower=1}
if algae_list[i][1] ~= nil then
num = "_"..algae_list[i][1]
algae_groups = { snappy = 3,flammable=2,flower=1, not_in_creative_inventory=1 }
end
minetest.register_node(":flowers:seaweed"..num, {
description = S("Seaweed"),
drawtype = "nodebox",
tiles = {
"flowers_seaweed"..num..".png",
"flowers_seaweed"..num..".png^[transformFY"
},
inventory_image = "flowers_seaweed_2.png",
wield_image = "flowers_seaweed_2.png",
sunlight_propagates = true,
paramtype = "light",
paramtype2 = "facedir",
walkable = false,
groups = algae_groups,
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = { -0.4, -0.5, -0.4, 0.4, -0.45, 0.4 },
},
node_box = {
type = "fixed",
fixed = { -0.5, -0.49, -0.5, 0.5, -0.49, 0.5 },
},
buildable_to = true,
liquids_pointable = true,
drop = "flowers:seaweed",
on_place = function(itemstack, placer, pointed_thing)
local keys=placer:get_player_control()
local pt = pointed_thing
local place_pos = nil
local top_pos = {x=pt.under.x, y=pt.under.y+1, z=pt.under.z}
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 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
place_pos = top_pos
else
return
end
elseif biome_lib:get_nodedef_field(above_node.name, "buildable_to") then
place_pos = pt.above
end
if not minetest.is_protected(place_pos, placer:get_player_name()) then
local nodename = "default:cobble" -- :D
if not keys["sneak"] then
--local node = minetest.get_node(pt.under)
local seaweed = math.random(1,4)
if seaweed == 1 then
nodename = "flowers:seaweed"
elseif seaweed == 2 then
nodename = "flowers:seaweed_2"
elseif seaweed == 3 then
nodename = "flowers:seaweed_3"
elseif seaweed == 4 then
nodename = "flowers:seaweed_4"
end
minetest.swap_node(place_pos, {name = nodename, param2 = math.random(0,3) })
else
local fdir = minetest.dir_to_facedir(placer:get_look_dir())
minetest.swap_node(place_pos, {name = "flowers:seaweed", param2 = fdir})
end
if not biome_lib.expect_infinite_stacks then
itemstack:take_item()
end
return itemstack
end
end,
})
end
local box = {
type="fixed",
fixed = { { -0.2, -0.5, -0.2, 0.2, 0.5, 0.2 } },
}
local sunflower_drop = "farming:seed_wheat"
if minetest.registered_items["farming:seed_spelt"] then
sunflower_drop = "farming:seed_spelt"
end
minetest.register_node(":flowers:sunflower", {
description = S("Sunflower"),
drawtype = "mesh",
paramtype = "light",
paramtype2 = "facedir",
inventory_image = "flowers_sunflower_inv.png",
mesh = "flowers_sunflower.obj",
tiles = { "flowers_sunflower.png" },
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = { dig_immediate=3, flora=1, flammable=3 },
sounds = default.node_sound_leaves_defaults(),
selection_box = box,
collision_box = box,
drop = {
max_items = 1,
items = {
{items = {sunflower_drop}, rarity = 8},
{items = {"flowers:sunflower"}},
}
}
})
local extra_aliases = {
"waterlily",
"waterlily_225",
"waterlily_45",
"waterlily_675",
"seaweed"
}
for i in ipairs(extra_aliases) do
local flower = extra_aliases[i]
minetest.register_alias("flowers:flower_"..flower, "flowers:"..flower)
end
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( "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" )
-- ongen registrations
flowers_plus.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_generate_plant({
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,
},
flowers_plus.grow_waterlily
)
flowers_plus.grow_seaweed = function(pos)
local right_here = {x=pos.x, y=pos.y+1, z=pos.z}
minetest.swap_node(right_here, {name="along_shore:seaweed_"..math.random(1,4), param2=math.random(1,3)})
end
biome_lib:register_generate_plant({
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,
},
flowers_plus.grow_seaweed
)
-- seaweed at beaches
-- MM: not satisfied with it, but IMHO some beaches should have some algae
biome_lib:register_generate_plant({
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
},
flowers_plus.grow_seaweed
)
biome_lib:register_generate_plant({
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
},
flowers_plus.grow_seaweed
)
biome_lib:register_generate_plant({
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.53,
random_facedir = {0,3},
},
"flowers:sunflower"
)
-- spawn ABM registrations
biome_lib:spawn_on_surfaces({
spawn_delay = SPAWN_DELAY/2,
spawn_plants = {
"flowers:waterlily",
"flowers:waterlily_225",
"flowers:waterlily_45",
"flowers:waterlily_675",
"flowers:waterlily_s1",
"flowers:waterlily_s2",
"flowers:waterlily_s3",
"flowers:waterlily_s4"
},
avoid_radius = 2.5,
spawn_chance = SPAWN_CHANCE*4,
spawn_surfaces = {"default:water_source"},
avoid_nodes = {"group:flower", "group:flora" },
seed_diff = flowers_seed_diff,
light_min = 9,
depth_max = 2,
random_facedir = {0,3}
})
biome_lib:spawn_on_surfaces({
spawn_delay = SPAWN_DELAY*2,
spawn_plants = {"flowers:seaweed"},
spawn_chance = SPAWN_CHANCE*2,
spawn_surfaces = {"default:water_source"},
avoid_nodes = {"group:flower", "group:flora"},
seed_diff = flowers_seed_diff,
light_min = 4,
light_max = 10,
neighbors = {"default:dirt_with_grass"},
facedir = 1
})
biome_lib:spawn_on_surfaces({
spawn_delay = SPAWN_DELAY*2,
spawn_plants = {"flowers:seaweed"},
spawn_chance = SPAWN_CHANCE*2,
spawn_surfaces = {"default:dirt_with_grass"},
avoid_nodes = {"group:flower", "group:flora" },
seed_diff = flowers_seed_diff,
light_min = 4,
light_max = 10,
neighbors = {"default:water_source"},
ncount = 1,
facedir = 1
})
biome_lib:spawn_on_surfaces({
spawn_delay = SPAWN_DELAY*2,
spawn_plants = {"flowers:seaweed"},
spawn_chance = SPAWN_CHANCE*2,
spawn_surfaces = {"default:stone"},
avoid_nodes = {"group:flower", "group:flora" },
seed_diff = flowers_seed_diff,
light_min = 4,
light_max = 10,
neighbors = {"default:water_source"},
ncount = 6,
facedir = 1
})
biome_lib:spawn_on_surfaces({
spawn_delay = SPAWN_DELAY*2,
spawn_plants = {"flowers:sunflower"},
spawn_chance = SPAWN_CHANCE*2,
spawn_surfaces = {"default:dirt_with_grass"},
avoid_nodes = {"group:flower", "flowers:sunflower"},
seed_diff = flowers_seed_diff,
light_min = 11,
light_max = 14,
min_elevation = 0,
plantlife_limit = -0.9,
temp_max = 0.53,
random_facedir = {0,3},
avoid_radius = 5
})
-- Cotton plants are now provided by the default "farming" mod.
-- old cotton plants -> farming cotton stage 8
-- cotton wads -> string (can be crafted into wool blocks)
-- potted cotton plants -> potted white dandelions
minetest.register_alias("flowers:cotton_plant", "farming:cotton_8")
minetest.register_alias("flowers:flower_cotton", "farming:cotton_8")
minetest.register_alias("flowers:flower_cotton_pot", "flowers:potted_dandelion_white")
minetest.register_alias("flowers:potted_cotton_plant", "flowers:potted_dandelion_white")
minetest.register_alias("flowers:cotton", "farming:string")
minetest.register_alias("flowers:cotton_wad", "farming:string")
minetest.register_alias("sunflower:sunflower", "flowers:sunflower")
print(S("[Flowers] Loaded."))

View File

@ -1,3 +0,0 @@
minetest.register_alias("junglegrass:shortest", "air")
minetest.register_alias("junglegrass:short", "air")
minetest.register_alias("junglegrass:medium", "air")

1
modpack.conf Normal file
View File

@ -0,0 +1 @@
min_minetest_version = 5.2.0

View File

@ -1,3 +0,0 @@
default
plantlife_i18n
biome_lib

View File

@ -1,17 +1,16 @@
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
local title = "Mole Hills"
local version = "0.0.3"
local mname = "molehills"
-----------------------------------------------------------------------------------------------
-- Idea by Sokomine -- Idea by Sokomine
-- Code & textures by Mossmanikin -- Code & textures by Mossmanikin
abstract_molehills = {} abstract_molehills = {}
dofile(minetest.get_modpath("molehills").."/molehills_settings.txt") 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 -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("molehills")
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
-- NoDe -- NoDe
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
@ -27,6 +26,7 @@ minetest.register_node("molehills:molehill",{
description = S("Mole Hill"), description = S("Mole Hill"),
inventory_image = "molehills_side.png", inventory_image = "molehills_side.png",
tiles = { "molehills_dirt.png" }, tiles = { "molehills_dirt.png" },
use_texture_alpha = "clip",
paramtype = "light", paramtype = "light",
selection_box = mh_cbox, selection_box = mh_cbox,
collision_box = mh_cbox, collision_box = mh_cbox,
@ -49,11 +49,11 @@ minetest.register_craft({ -- molehills --> dirt
-- GeNeRaTiNG -- GeNeRaTiNG
----------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------
abstract_molehills.place_molehill = function(pos) abstract_molehills.place_molehill = function(pos)
local right_here = {x=pos.x , y=pos.y+1, z=pos.z } 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" 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-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 , 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"
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"
@ -62,19 +62,14 @@ abstract_molehills.place_molehill = function(pos)
end end
end end
biome_lib:register_generate_plant({ pl.register_on_generate({
surface = {"default:dirt_with_grass"}, surface = {"default:dirt_with_grass"},
max_count = Molehills_Max_Count, noise_params = pl.generate_noise_params({rarity = molehills_rarity, rarity_fertility = molehills_rarity_fertility}),
rarity = Molehills_Rarity, min_elevation = 1,
min_elevation = 1, max_elevation = 40,
max_elevation = 40, avoid_nodes = {"group:tree","group:liquid","group:stone","group:falling_node"},
avoid_nodes = {"group:tree","group:liquid","group:stone","group:falling_node"--[[,"air"]]}, avoid_radius = 4,
avoid_radius = 4, },
plantlife_limit = -0.3, "molehills:molehills",
}, abstract_molehills.place_molehill
abstract_molehills.place_molehill
) )
-----------------------------------------------------------------------------------------------
print("[Mod] "..title.." ["..version.."] ["..mname.."]"..S("Loaded..."))
-----------------------------------------------------------------------------------------------

View File

@ -0,0 +1,9 @@
# 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

View File

@ -0,0 +1,9 @@
# 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

View File

@ -0,0 +1,9 @@
# 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 <fat115@framasoft.org>, 2017.
#
Mole Hill=Taupinière

View File

@ -0,0 +1,9 @@
# 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 <EMAIL@ADDRESS>, YEAR.
#
Mole Hill=

2
molehills/mod.conf Normal file
View File

@ -0,0 +1,2 @@
name = molehills
depends = default, biome_lib

View File

@ -1,6 +0,0 @@
-- Settings for generation of stuff (at map-generation time)
Molehills_Max_Count = 320 -- absolute maximum number in an area of 80x80x80 nodes
Molehills_Rarity = 95 -- larger values make molehills more rare (100 means chance of 0 %)

View File

@ -0,0 +1,8 @@
#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

View File

@ -1,5 +1,5 @@
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("nature_classic")
-- Blossoms and such -- Blossoms and such
local function spawn_apple_under(pos) local function spawn_apple_under(pos)

View File

@ -1,3 +0,0 @@
default
plantlife_i18n
moretrees?

View File

@ -7,7 +7,7 @@ local current_mod_name = minetest.get_current_modname()
nature = {} nature = {}
-- support for i18n -- support for i18n
local S = plantlife_i18n.gettext local S = minetest.get_translator("nature_classic")
nature.blossomqueue = {} nature.blossomqueue = {}
nature.blossomqueue_max = 1000 nature.blossomqueue_max = 1000

Some files were not shown because too many files have changed in this diff Show More