Vanessa's plants/biome libraryThis library's purpose is to allow other mods to add growing things to the map in a straightforward, simple manner. It contains all the core functions needed by mods and modpacks such as More Trees, Tiny Trees, Plantlife, and others.
Spawning of plants is optionally sensitive to the amount of available light, elevation, nearness to other nodes, plant-to-plant density, water depth, and a whole host of controls.
All objects spawned or generated using this mod use Perlin noise to stay within simple biomes, rather than just letting everything just spread around the map randomly.
This library also features a basic temperature map, which should blend in nicely with SPlizard's Snow Biomes mod (the same Perlin settings are used, with the assumption that the edge of a snow biome is 0° Centigrade).
Both mapgen-based spawning and ABM-based spawning is supported. The active growing code is strictly ABM-based. L-system trees can be spawned at mapgen time via the engine's spawn_tree() function.
It is aimed primarily at mapgen v6, and does not use the biome capabilities supplied by mapgen v7 (that will change some day). As such, if used in a mapgen v7 world, it'll work just fine but the temperature and humidity maps will not match up the way you might expect.
On server-exit, biome_lib will "hang" the server for a bit so that it can play out the rest of its deferred-generation log. This process may take a couple of minutes, and is done to prevent areas being left under-populated.
This mod was formerly known as "plants_lib" and used to be included in the Plantlife Modpack.
Dependencies: default from minetest_game
Recommends: Plantlife Modpack, More Trees
Download: https://gitlab.com/VanessaE/biome_lib/- ... master.zip
...or browse the code: https://gitlab.com/VanessaE/biome_lib
License: LGPL 3.0 for code, CC-by-SA 4.0 for media and everything else.
API: This mod supplies a small number of very powerful functions. They are, briefly:
Code: Select all
biome_lib:register_generate_plant() biome_lib:spawn_on_surfaces() biome_lib:grow_plants() biome_lib:find_valid_wall() biome_lib:is_node_loaded()