summaryrefslogtreecommitdiff
path: root/src/mapgen/mapgen_v6.cpp
Commit message (Collapse)AuthorAge
* Give the Mapgen on each EmergeThread its own Biome/Ore/Deco/SchemManager copysfan52020-05-05
|
* Drop content_sao.{cpp,h}Loic Blot2020-04-11
| | | | | | | Move LuaEntitySAO to a new dedicated file Drop TestSAO (useless object) Drop the old static startup initialized SAO factory, which was pretty useless. This factory was using a std::map for 2 elements, now just use a simple condition owned by ServerEnvironment, which will be lightweight, that will also drop a one time useful test on each LuaEntitySAO creation. This should reduce server load on massive SAO creation
* Move serveractiveobject & unitsaoLoic Blot2020-04-11
| | | | | Move serverobject.{cpp,h} to server/serveractiveobject.{cpp,h} Move UnitSAO class to dedicated files
* Print error if invalid mapgen alias was detected (#9579)Wuzzy2020-04-10
|
* Settings: Add get_flags API for mapgen flags (mg_flags, mgv6_spflags, ...) ↵SmallJoker2020-01-25
| | | | | | | | | | | (#9284) Unified flags handling in C++ and Lua Settings API -> Reading only, for now. Writing can be implemented later, if needed. API function to read the currently active flags -> was impossible from Lua Co-authored-by: Wuzzy <wuzzy2@mail.ru>
* Mapgen v6: Various mudflow code improvements and bugfixes (#8805)Paramat2019-08-24
| | | | | | | | | | | | | | | Calculate 'i' inside 'y' loop to avoid 'i' and 'y' becoming out of step due to the uses of 'continue'. Simplify calculation of 'p2d' when coordinates are inverted. Remove some unnecessary and unreliable 'index out of voxelmanip' checks. Move calculation of '&em' out of loops. For 'Loop further down until not air' code, use y coordinate to detect being out of voxelmanip, instead of checking index which did not detect that. Add and improve comments. Indent the 'for (;; y--) {' loop. Improve format and fix codestyle issues.
* Mapgen v6: Fix mudflow iteration and iterate twice (#8795)Paramat2019-08-15
| | | | | | | | | | In MapgenV6::flowMud(), the previous implementation of coordinate inversion caused the 2 inverted mudflow iterations (out of the 3 iterations) to not loop over the area, so only 1 non-inverted iteration occurred. Fix this bug but only iterate mudflow twice, as mapgen v6 has only had 1 iteration for many years. There is now a good balance of 1 non-inverted iteration and 1 inverted iteration.
* Dungeons: Make multiple large rooms possible (#8678)Paramat2019-07-16
| | | | | | | | | 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 more dungeon parameter selection to mapgens (#8653)Paramat2019-07-09
| | | | | | | | | | 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.
* Dungeons: Settable density noise, move number calculation to mapgens (#8473)Paramat2019-06-01
| | | | | | | | | | | | 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.
* mapgen: drop mapgen id from child mapgens.Loïc Blot2019-03-31
| | | | | | 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
* Dungeons: Fix duplication of y limit parameters (#7359)Paramat2018-05-20
|
* VoxelArea: add_{x,y,z,p} must be staticLoic Blot2018-03-09
| | | | | Fix some documentations issues Use getNodeNoCheck(v3s16, ...) in some cases instead of getNodeNoCheck(x, y, z, ...)
* Dungeons: Add Y limits in all mapgensparamat2018-02-20
| | | | Preserve the upper limit used in mgvalleys.
* Dungeons: Avoid generation in multiple liquid nodes and 'airlike'paramat2018-02-13
| | | | | | | | | | | | | | 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.
* Node definition manager refactor (#7016)Dániel Juhász2018-02-10
| | | | | | | | | * Rename IWritableNodeDefManager to NodeDefManager * Make INodeDefManager functions const * Use "const *NodeDefManager" instead of "*INodeDefManager" * Remove unused INodeDefManager class * Merge NodeDefManager and CNodeDefManager * Document NodeDefManager
* Mapgen folder: Update and improve copyright information of filesparamat2018-01-15
|
* Move files to subdirectories (#6599)Vitaliy2017-11-08
* Move files around