1
0
mirror of https://github.com/mt-mods/plantlife_modpack.git synced 2025-06-28 14:16:11 +02:00

Split the flowers/junglegrass/poisonivy components into separate folders,

leaving the plants folder as the primary API code and glue between them.  Any
of the three may be deleted to disable them if so desired.
This commit is contained in:
Vanessa Ezekowitz
2012-12-03 17:20:50 -05:00
parent 9e6e47cb99
commit 2942f2366f
10 changed files with 324 additions and 324 deletions

View File

@ -0,0 +1 @@
plants

View File

@ -0,0 +1,79 @@
-- This file supplies jungle grass for the plantlife modpack
local spawn_delay = 2000 -- 2000
local spawn_chance = 100 -- 100
local grow_delay = 1000 -- 1000
local grow_chance = 10 -- 10
local grasses_list = {
{"junglegrass:shortest","junglegrass:short" },
{"junglegrass:short" ,"junglegrass:medium" },
{"junglegrass:medium" ,"default:junglegrass" },
{"default:junglegrass" , nil}
}
minetest.register_node(':junglegrass:medium', {
description = "Jungle Grass (medium height)",
drawtype = 'plantlike',
tile_images = { 'junglegrass_medium.png' },
inventory_image = 'junglegrass_medium.png',
wield_image = 'junglegrass_medium.png',
sunlight_propagates = true,
paramtype = 'light',
walkable = false,
groups = { snappy = 3, flammable=2, junglegrass=1 },
sounds = default.node_sound_leaves_defaults(),
drop = 'default:junglegrass',
selection_box = {
type = "fixed",
fixed = {-0.4, -0.5, -0.4, 0.4, 0.5, 0.4},
},
})
minetest.register_node(':junglegrass:short', {
description = "Jungle Grass (short)",
drawtype = 'plantlike',
tile_images = { 'junglegrass_short.png' },
inventory_image = 'junglegrass_short.png',
wield_image = 'junglegrass_short.png',
sunlight_propagates = true,
paramtype = 'light',
walkable = false,
groups = { snappy = 3, flammable=2, junglegrass=1 },
sounds = default.node_sound_leaves_defaults(),
drop = 'default:junglegrass',
selection_box = {
type = "fixed",
fixed = {-0.4, -0.5, -0.4, 0.4, 0.3, 0.4},
},
})
minetest.register_node(':junglegrass:shortest', {
description = "Jungle Grass (very short)",
drawtype = 'plantlike',
tile_images = { 'junglegrass_shortest.png' },
inventory_image = 'junglegrass_shortest.png',
wield_image = 'junglegrass_shortest.png',
sunlight_propagates = true,
paramtype = 'light',
walkable = false,
groups = { snappy = 3, flammable=2, junglegrass=1 },
sounds = default.node_sound_leaves_defaults(),
drop = 'default:junglegrass',
selection_box = {
type = "fixed",
fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3},
},
})
spawn_on_surfaces(spawn_delay*2, "junglegrass:shortest", 4, spawn_chance, "default:dirt_with_grass", {"group:junglegrass", "default:junglegrass", "default:dry_shrub"}, junglegrass_seed_diff, 5)
spawn_on_surfaces(spawn_delay*2, "junglegrass:shortest", 4, spawn_chance*2, "default:sand" , {"group:junglegrass", "default:junglegrass", "default:dry_shrub"}, junglegrass_seed_diff, 5)
spawn_on_surfaces(spawn_delay*2, "junglegrass:shortest", 4, spawn_chance*3, "default:desert_sand" , {"group:junglegrass", "default:junglegrass", "default:dry_shrub"}, junglegrass_seed_diff, 5)
spawn_on_surfaces(spawn_delay*2, "junglegrass:shortest", 4, spawn_chance*3, "default:desert_sand" , {"group:junglegrass", "default:junglegrass", "default:dry_shrub"}, junglegrass_seed_diff, 5)
for i in ipairs(grasses_list) do
grow_plants(grow_delay, grow_chance/2, grasses_list[i][1], grasses_list[i][2], "default:desert_sand", {"default:dirt_with_grass", "default:sand", "default:desert_sand"})
end
enabled_junglegrass = true

View File

@ -0,0 +1,24 @@
Changelog
---------
2012-08-03: Mild rewrite to adapt the mod to use perlin noise while spawning.
Also got rid of the random-numbers-inside-abm stuff, now using the abm's own
'chance' parameter instead. Tuned various settings to try to retain the same
overall density and growth rates as in the previous version. Moved this
changelog into a separate file.
2012-07-12: moved project to github.
2012-07-09 (a bit later): tuned the spawn/grow rates a bit more, made the
numbers more sane. Added a radius check to limit the density of the spawned
grasses (they won't grow near each other or near dry shrubs or cactus, though
they still grow on the top of said cacti).
2012-07-09: Added cactus, sand, and desert sand as spawning surfaces. Reduced
and tuned the spawn rates a bit to try to balance things out. Made that which
spawns on grass, dirt, or sand start out at any size, grow over time, and
eventually die off. Limited desert sand to only the first two sizes (the
smallest size will grow one step, eventually), which will eventually die and
turn into dry shrubs. Only the two smallest sizes can spawn on cactus or
papyrus (and they don't grow or die). Fixed slightly off-center smallest size.
Fixed selection boxes.