Luanti 5.11.0-dev
 
Loading...
Searching...
No Matches
MapgenValleys Class Reference

#include <mapgen_valleys.h>

+ Inheritance diagram for MapgenValleys:
+ Collaboration diagram for MapgenValleys:

Public Member Functions

 MapgenValleys (MapgenValleysParams *params, EmergeParams *emerge)
 
 ~MapgenValleys ()
 
virtual MapgenType getType () const
 
virtual void makeChunk (BlockMakeData *data)
 
int getSpawnLevelAtPoint (v2s16 p)
 
- Public Member Functions inherited from MapgenBasic
 MapgenBasic (int mapgenid, MapgenParams *params, EmergeParams *emerge)
 
virtual ~MapgenBasic ()
 
virtual void generateBiomes ()
 
virtual void dustTopNodes ()
 
virtual void generateCavesNoiseIntersection (s16 max_stone_y)
 
virtual void generateCavesRandomWalk (s16 max_stone_y, s16 large_cave_ymax)
 
virtual bool generateCavernsNoise (s16 max_stone_y)
 
virtual void generateDungeons (s16 max_stone_y)
 
- Public Member Functions inherited from Mapgen
 Mapgen ()=default
 
 Mapgen (int mapgenid, MapgenParams *params, EmergeParams *emerge)
 
virtual ~Mapgen ()
 
 DISABLE_CLASS_COPY (Mapgen)
 
s16 findGroundLevel (v2s16 p2d, s16 ymin, s16 ymax)
 
s16 findLiquidSurface (v2s16 p2d, s16 ymin, s16 ymax)
 
void updateHeightmap (v3s16 nmin, v3s16 nmax)
 
void getSurfaces (v2s16 p2d, s16 ymin, s16 ymax, std::vector< s16 > &floors, std::vector< s16 > &ceilings)
 
void updateLiquid (UniqueQueue< v3s16 > *trans_liquid, v3s16 nmin, v3s16 nmax)
 
void setLighting (u8 light, v3s16 nmin, v3s16 nmax)
 Set light in entire area to fixed value.
 
void calcLighting (v3s16 nmin, v3s16 nmax, v3s16 full_nmin, v3s16 full_nmax, bool propagate_shadow=true)
 Run all lighting calculations.
 
void propagateSunlight (v3s16 nmin, v3s16 nmax, bool propagate_shadow)
 Spread sunlight from the area above downwards.
 
void spreadLight (const v3s16 &nmin, const v3s16 &nmax)
 Spread light in the given area.
 
virtual int getGroundLevelAtPoint (v2s16 p)
 

Private Member Functions

virtual int generateTerrain ()
 

Private Attributes

BiomeGenOriginalm_bgen
 
float altitude_chill
 
float river_depth_bed
 
float river_size_factor
 
Noisenoise_inter_valley_fill
 
Noisenoise_inter_valley_slope
 
Noisenoise_rivers
 
Noisenoise_terrain_height
 
Noisenoise_valley_depth
 
Noisenoise_valley_profile
 

Additional Inherited Members

- Static Public Member Functions inherited from Mapgen
static u32 getBlockSeed (v3s16 p, s32 seed)
 
static u32 getBlockSeed2 (v3s16 p, s32 seed)
 
static MapgenType getMapgenType (const std::string &mgname)
 
static const char * getMapgenName (MapgenType mgtype)
 
static MapgencreateMapgen (MapgenType mgtype, MapgenParams *params, EmergeParams *emerge)
 
static MapgenParamscreateMapgenParams (MapgenType mgtype)
 
static void getMapgenNames (std::vector< const char * > *mgnames, bool include_hidden)
 
static void setDefaultSettings (Settings *settings)
 
- Public Attributes inherited from Mapgen
s32 seed = 0
 
int water_level = 0
 
int mapgen_limit = 0
 
u32 flags = 0
 
bool generating = false
 
int id = -1
 
MMVManipvm = nullptr
 
EmergeParamsm_emerge = nullptr
 
const NodeDefManagerndef = nullptr
 
u32 blockseed
 
s16 * heightmap = nullptr
 
biome_tbiomemap = nullptr
 
v3s16 csize
 
BiomeGenbiomegen = nullptr
 
GenerateNotifier gennotify
 
- Protected Attributes inherited from MapgenBasic
BiomeManagerm_bmgr
 
Noisenoise_filler_depth
 
v3s16 node_min
 
v3s16 node_max
 
v3s16 full_node_min
 
v3s16 full_node_max
 
content_t c_stone
 
content_t c_water_source
 
content_t c_river_water_source
 
content_t c_lava_source
 
content_t c_cobble
 
int ystride
 
int zstride
 
int zstride_1d
 
int zstride_1u1d
 
u32 spflags
 
NoiseParams np_cave1
 
NoiseParams np_cave2
 
NoiseParams np_cavern
 
NoiseParams np_dungeons
 
float cave_width
 
float cavern_limit
 
float cavern_taper
 
float cavern_threshold
 
int small_cave_num_min
 
int small_cave_num_max
 
int large_cave_num_min
 
int large_cave_num_max
 
float large_cave_flooded
 
s16 large_cave_depth
 
s16 dungeon_ymin
 
s16 dungeon_ymax
 

Constructor & Destructor Documentation

◆ MapgenValleys()

MapgenValleys::MapgenValleys ( MapgenValleysParams * params,
EmergeParams * emerge )

References altitude_chill, MapgenValleysParams::altitude_chill, Mapgen::biomegen, BIOMEGEN_ORIGINAL, MapgenBasic::cave_width, MapgenValleysParams::cave_width, MapgenBasic::cavern_limit, MapgenValleysParams::cavern_limit, MapgenBasic::cavern_taper, MapgenValleysParams::cavern_taper, MapgenBasic::cavern_threshold, MapgenValleysParams::cavern_threshold, Mapgen::csize, MapgenBasic::dungeon_ymax, MapgenValleysParams::dungeon_ymax, MapgenBasic::dungeon_ymin, MapgenValleysParams::dungeon_ymin, FATAL_ERROR_IF, BiomeGen::getType(), MapgenBasic::large_cave_depth, MapgenValleysParams::large_cave_depth, MapgenBasic::large_cave_flooded, MapgenValleysParams::large_cave_flooded, MapgenBasic::large_cave_num_max, MapgenValleysParams::large_cave_num_max, MapgenBasic::large_cave_num_min, MapgenValleysParams::large_cave_num_min, m_bgen, MapgenBasic::noise_filler_depth, noise_inter_valley_fill, noise_inter_valley_slope, noise_rivers, noise_terrain_height, noise_valley_depth, noise_valley_profile, MapgenBasic::np_cave1, MapgenValleysParams::np_cave1, MapgenBasic::np_cave2, MapgenValleysParams::np_cave2, MapgenBasic::np_cavern, MapgenValleysParams::np_cavern, MapgenBasic::np_dungeons, MapgenValleysParams::np_dungeons, MapgenValleysParams::np_filler_depth, MapgenValleysParams::np_inter_valley_fill, MapgenValleysParams::np_inter_valley_slope, MapgenValleysParams::np_rivers, MapgenValleysParams::np_terrain_height, MapgenValleysParams::np_valley_depth, MapgenValleysParams::np_valley_profile, MapgenValleysParams::river_depth, river_depth_bed, MapgenValleysParams::river_size, river_size_factor, Mapgen::seed, MapgenBasic::small_cave_num_max, MapgenValleysParams::small_cave_num_max, MapgenBasic::small_cave_num_min, MapgenValleysParams::small_cave_num_min, MapgenBasic::spflags, and MapgenParams::spflags.

+ Here is the call graph for this function:

◆ ~MapgenValleys()

Member Function Documentation

◆ generateTerrain()

◆ getSpawnLevelAtPoint()

int MapgenValleys::getSpawnLevelAtPoint ( v2s16 p)
virtual

Reimplemented from Mapgen.

References MAX_MAP_GENERATION_LIMIT, noise_inter_valley_fill, noise_inter_valley_slope, noise_rivers, noise_terrain_height, noise_valley_depth, noise_valley_profile, NoisePerlin2D(), NoisePerlin3D(), Noise::np, NoiseParams::offset, p(), river_size_factor, Mapgen::seed, and Mapgen::water_level.

+ Here is the call graph for this function:

◆ getType()

virtual MapgenType MapgenValleys::getType ( ) const
inlinevirtual

Reimplemented from Mapgen.

References MAPGEN_VALLEYS.

◆ makeChunk()

Member Data Documentation

◆ altitude_chill

float MapgenValleys::altitude_chill
private

Referenced by MapgenValleys(), and generateTerrain().

◆ m_bgen

BiomeGenOriginal* MapgenValleys::m_bgen
private

◆ noise_inter_valley_fill

Noise* MapgenValleys::noise_inter_valley_fill
private

◆ noise_inter_valley_slope

Noise* MapgenValleys::noise_inter_valley_slope
private

◆ noise_rivers

Noise* MapgenValleys::noise_rivers
private

◆ noise_terrain_height

Noise* MapgenValleys::noise_terrain_height
private

◆ noise_valley_depth

Noise* MapgenValleys::noise_valley_depth
private

◆ noise_valley_profile

Noise* MapgenValleys::noise_valley_profile
private

◆ river_depth_bed

float MapgenValleys::river_depth_bed
private

Referenced by MapgenValleys(), and generateTerrain().

◆ river_size_factor

float MapgenValleys::river_size_factor
private

The documentation for this class was generated from the following files: