| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
|
| |
Update the profiler names to make more sense of what they actually represent
Move the profiler code from header to its source file
Use monospace font to align lines
Format the statistics line to align better with surrounding values
Refresh the profiler each 3 seconds (roughly)
|
|
|
|
|
|
| |
v6 always last to discourage selection.
Special mapgens flat, fractal, singlenode, next to last. Of these, singlenode
last to discourage selection.
Of the remaining, v5 last due to age, v7 first due to being the default.
|
|
|
|
|
|
|
|
|
| |
Re-add the random size range for large rooms.
Remove 'first_room_large' bool.
Add 'large_room_chance' parameter that can disable large rooms,
specify 1 large room, or specify a chance for large rooms.
If 1 or a chance is specified, the first generated room is large,
to take advantage of the intersection checks that are done for the
1st room only.
|
|
|
|
|
|
|
|
|
|
| |
Move 'num_dungeons' to 'DungeonParams'.
Add new parameter 'num_rooms' to replace 'rooms_min' and 'rooms_max',
so that the mapgen has complete control over the number of rooms.
Add new bool 'first_room_large' so that the mapgen chooses this
instead of a hardcoded 1 in 4 chance.
Add new parameter 'room_size_large' to replace 'room_size_large_min'
and 'room_size_large_max', so that the mapgen has complete control
over this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Biome-defined dungeon nodes was added as a feature to MT 5.0.0.
So now remove most of the hardcoded dungeon node code that assumes a
game has stone, sandstone, desert stone, and no other stone types.
If biome-defined dungeon nodes are not found, dungeon nodes fall back
to the 'cobble' mapgen alias if present, if not present they fall back
to biome-defined 'stone'.
Remove now-unnecessary mapgen aliases from MapgenBasic. Non-mgv6 games
now only need to define 3 to 5 mapgen aliases.
Document dungeon parameters.
Make c_lava_source fallback to c_water_source as both are used as cave
liquids.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add user-settable noise parameters for dungeon density to each mapgen,
except V6 which hardcodes this noise parameter.
Move the calculation of number of dungeons generated in a mapchunk out
of dungeongen.cpp and into mapgen code, to allow mapgens to generate
any desired number of dungeons in a mapchunk, instead of being forced
to have number of dungeons determined by a density noise.
This is more flexible and allows mapgens to use dungeon generation to
create custom structures, such as occasional mega-dungeons.
|
| |
|
|
|
|
|
|
| |
This id must be owned by the child mapgen and never be set to a misc value by a developer
Also use nullptr in some places
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, the biomemap was 'BIOME_NONE' for a mapchunk column if a
stone surface was not found in it, causing water surface decorations
and water surface dust to fail.
Store the biome ID of the biome calculated at a water surface and add
it to the biomemap if the biomemap is 'BIOME_NONE' for the mapchunk
column. The biome calculated at a stone surface still has priority
for the biomemap entry, as it should.
Edit an incorrect comment.
|
|
|
|
|
|
|
|
|
| |
Revert commit 99143f494711034068685b6ee845ce19fa09d7d9 and commit
f4ca830abe1aa22875c99b31bf2ee56e26f83f05.
These commits caused biome dust to be applied even when there was no core
mapgen terrain in a mapchunk column. So the dust, which overgenerates,
then appeared on structures added by mods in 'on_generated', such as
floatlands, asteroids or above-surface realms.
|
|
|
|
|
|
|
|
|
| |
Previously the only way to disable biomes was to 'clear' the registered
biomes in a mod, but this method causes large amounts of unnecessary
processing:
1. Calculation of 4 2D noises.
2. Looping through all nodes of a mapchunk replacing nodes with identical
nodes.
The new flag disables those operations.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
'generateBiomes()' constructs the biomemap as it generates biomes.
The biome calculated at first stone surface encountered is added to
the biomemap.
Previously, if no stone surface was encountered in a mapchunk column
the biomemap was left empty for that (x, z) position, causing biome
dust and water surface decoration placement to fail.
If at the base of a mapchunk column the biomemap is empty, add the
currently active biome to the biomemap, or if biome is NULL calculate
it for this position and add it to the biomemap.
|
| |
|
|
|
|
|
|
|
| |
Previously, caverns confused tunnel generation causing biome top and filler
nodes to appear in caverns.
Split 'generateCaves()' into 2 functions to separate tunnel and large
randomwalk cave generation.
In each mapgen re-order cave generation to generate tunnels before caverns.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Add new biome fields 'node_dungeon', 'node_dungeon_alt', 'node_dungeon_stair'.
If 'node_dungeon' is not defined dungeons fall back to classic behaviour.
Remove messy and imprecise dungeon material code from 'generateBiomes()'.
Code deciding dungeon materials is now in 'generateDungeons()' and uses the
biome at mapchunk centre for more precision.
Remove hardcoded 'MG_STONE' types as long intended.
|
|
|
|
| |
Add 'node_cave_liquid' as a new field in biome registration.
If field is absent cave liquids fall back to classic behaviour.
|
|
|
|
|
| |
Fix some documentations issues
Use getNodeNoCheck(v3s16, ...) in some cases instead of getNodeNoCheck(x, y, z, ...)
|
|
|
|
| |
'y_min' and 'y_max' are still accepted for compatibility.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously only 'mapgen water source' and 'mapgen river water source'
were checked for. Games can use multiple liquid nodes defined for biomes,
many of which will not be aliased to those 2 mapgen aliases, causing
floating dungeons to generate in some liquids.
Now we check for liquid drawtype instead, so can remove liquid nodes
from dungeonparams.
Also check for 'airlike' drawtype instead of 'CONTENT_AIR' to avoid
generation in 'airlike' nodes in some rare situations. This will also be
needed for when we add definable biome air nodes.
|
| |
|
| |
|
|
|
|
|
|
| |
No longer decide placement on 'buildable_to' parameter.
Dust nodes only look acceptable placed on cubic nodes.
Modders may not want to make their plantlike decorations 'buildable_to'.
|
|
* Move files around
|