| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, findSpawnPos() did not take the 'mapgen_limit' setting into account,
a small limit often resulted in a spawn out in the void.
Use the recently added 'calcMapgenEdges()' to get max spawn range through a new
mapgenParams function 'getSpawnRangeMax()'.
Previously, when a player respawned into a world, 'objectpos_over_limit()' was
used as a check, which was inaccurate.
Use the recently added 'saoPosOverLimit()' to get exact mapgen edges.
Also fix default value of 'm_sao_limit_min'.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* LuaEntitySAO: Remove beyond outermost mapchunk edges
Based on a commit by, and with help from, nerzhul.
Add 2 functions to class Mapgen:
A function to calculate actual mapgen edges, called from the Mapgen constructor.
A function called indirectly from content_sao.cpp per entity step to check SAO
position is within mapgen edges.
* Calculate borders from params not mapgen, which is not available everytime
|
| |
|
|
|
|
| |
Future mapgens are likely to use this for magma and volcanos.
Remove the getting of lava source content id in mgvalleys.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add to MapgenBasic for use by multiple mapgens.
Add to mgv5 and mgv7, enabled by default.
Similar to mgvalleys caverns but half the scale.
Parameters for upper y limit, distance caverns taper to full size, and
noise threshold (full cavern size).
As with mgvalleys caverns are generated first and classic caves are
disabled in any mapchunk containing a cavern, to avoid excessive
spreading volumes of liquids.
This also avoids floating blobs of liquid where a large classic cave
has overgenerated out into a neighbouring previously-generated mapchunk.
|
|
|
|
|
|
|
|
|
|
|
| |
The setting limits map generation but affects nothing else.
Add 'mapgen_limit' to global mapgen parameters.
Move 'blockpos_over_mapgen_limit()' to the only place it is called
from: map.cpp.
Allow teleportation to any part of the world even if over the set
mapgen limit.
Simplify the reading of this limit in mgvalleys.
Remove the 'map_generation_limit' setting.
|
|
|
|
|
| |
Affects only sandstone dungeons. Nodebox stairs made from
'sandstone_block' look better because every step is undivided.
|
|
|
|
|
|
|
|
|
|
| |
Desert and sandstone dungeons have 2 node wide corridors. Previously,
nodebox stairs were disabled because dungeon generation code did not
support nodebox stairs wider than 1 node, now it does.
Add 'stair desert stone' content id to MappgenBasic.
Requires 'mapgen stair desert stone' to be added to Minetest Game.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the 'flat' and 'trees' flags were moved into mgv6_spflags they
were left in mg_flags in an attempt to support old mgv6 worlds. However
their appearence in mg_flags causes confusion, also, later, old-world
support was found to be broken for mgv6 worlds with 'notrees'.
This commit cleans up the mess and comes a month after a thread warning
of the change, and explaining the required action, was posted in the
news subforum. Only old mgv6 worlds with 'flat' or 'notrees' are
affected, a small minority of worlds, the required action being
correctly setting these flags in mgv6_spflags.
Disable a section of the 'map settings manager' unit test which is to
be changed as it is causing problems for pull requests.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit refactors the majority of the Mapgen settings system.
- MapgenParams is now owned by MapSettingsManager, itself a part of ServerMap,
instead of the EmergeManager.
- New Script API functions added:
core.get_mapgen_setting
core.get_mapgen_setting_noiseparams,
core.set_mapgen_setting, and
core.set_mapgen_setting_noiseparams.
- minetest.get/set_mapgen_params are deprecated by the above new functions.
- It is now possible to view and modify any arbitrary mapgen setting from a mod,
rather than the base MapgenParams structure.
- MapgenSpecificParams has been removed.
|
|
|
|
|
|
| |
- Move mapgen creation logic out of EmergeManager and into Mapgen
- Internally represent mapgen type as an enum value, instead of a string
- Remove the need for a MapgenFactory per mapgen
|
|
|
|
|
|
|
|
| |
- Adds only ~100 nodes per chunk to trans_liquid with similar processing time
- Adds liquid nodes themselves instead of potential solid nodes below them
- CONTENT_IGNORE nodes are interpreted as if they continue their neighborhood
- This allows liquid columns to span multiple chunks without being interrupted
- NOTE: Expects an one-node border in generation chunk without liquid changes
|
| |
|
|
|
|
|
| |
This fixes value truncation (and therefore incompatibility) on platforms
with an LP32 data model, such as VAX or MS-DOS.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This commit condenses the above methods into a single implementation used by
V7, V5, Flat, Fractal, and Valleys mapgens and introduces MapgenBasic.
|
|
|
|
|
|
|
| |
BiomeGen defines an interface that, given a set of BiomeParams, computes biomes
for a given area using the algorithm implemented by that specific BiomeGen.
This abstracts away the old system where each mapgen supplied the noises
required for biome generation.
|
|
|
|
|
|
|
|
|
|
|
|
| |
To avoid spawn search failing in new specialised mapgens
Increase spawn search range to 4000 nodes
Add getSpawnLevelAtPoint() functions to EmergeManager, class Mapgen
and all mapgens
Remove getGroundLevelAtPoint() functions from all mapgens except mgv6
(possibly to be re-added later in the correct form to return actual
ground level)
Make mgvalleys flag names consistent with other mapgens
Remove now unused 'vertical spawn range' setting
|
|
|
|
|
|
|
|
|
|
| |
To terminate unwanted shadows from floatlands or realms above
Also add to LuaVoxelManip calc_lighting for use in mapgen mods
Remove the 2 argument calcLighting, mapgens now use the 5
argument form to specify the volumes for propagateSunlight and
spreadLight
In mgsinglenode replace calcLighting with setLighting and
clean-up use of tabs and spaces
|
|
|
|
|
|
|
|
|
|
| |
Flag is set by default in MapgenParams
The global 'trees' flag remains but is now
undocumented and unset by default in MapgenParams
Add mgv6_spflag 'trees' set by default in
defaultsettings.cpp to affect new worlds only
This is automatically backwards
compatible for existing worlds
|
|
|
|
|
|
|
|
|
| |
Use this macro to disallow copying of an object using the assignment
operator or copy constructor. This catches otherwise silent-but-deadly
mistakes such as "ServerMap map = env->getMap();" at compile time.
If so desired, it is still possible to copy a class, but it now requires
an explicit call to memcpy or std::copy.
|
|
|
|
|
| |
Add findLiquidSurface() function to mapgen.cpp
Update lua_api.txt
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Make gamedef optional when constructing an ObjDefManager
Add note about object ownership
|
| |
|
|
|
|
|
|
|
| |
- General code cleanup
- Unified object creation and loading
- Specifying objects in APIs is now orthogonal (i.e. anything can take an ID,
name string, or the raw table definition (and automatically registers if present
|
|
|
|
| |
Add core.clear_registered_schematics() and refactor schematics somewhat
|
| |
|
|
|
|
|
|
|
| |
std::vector on Environment.cpp"
This reverts parts of commit 9749d9fee6db99da1ab861dc04ec63ef973db3e0, which breaks node resolver
list clearing
|
| |
|
|
|
|
| |
-MAP_GENERATION_LIMIT if surface not found
|
| |
|
| |
|
|
|
|
|
|
|
| |
std::vector on Environment.cpp
* Also change some std::list to std::vector for ClientMap::renderMap
* Remove disabled code in ClientMap::renderMap, disabled since a long time
|
| |
|
|
|
|
| |
This fixes the Mapgen V5 calcLighting segfault
|
|
|
|
|
|
|
|
|
|
|
| |
The cause of a single light source seemingly being lit without spread
was due to its creation in the +Y mapblock boundary layer during map
generation, which was ignored as the overtop. This overtop explicitly
needs to be omitted during sunlight propagation, however. To accomplish
this, Mapgen::calcLighting() was split into separate functions taking
separate parameters.
Additionally, do not diminish light too early during spread. This fixes the
output inconsistency between Map::updateLighting and Mapgen::calcLighting.
|
| |
|
| |
|