1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-07-27 17:28:41 +00:00

Class-ify caves & move to cavegen.cpp, fix cave regression, add caves to Mapgen V7

This commit is contained in:
kwolekr 2013-04-21 00:11:05 -04:00
parent 527deb947c
commit 03868ff8e1
10 changed files with 459 additions and 308 deletions

View file

@ -23,7 +23,6 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "mapgen.h"
#define AVERAGE_MUD_AMOUNT 4
#define VMANIP_FLAG_CAVE VOXELFLAG_CHECKED1
enum BiomeType
{
@ -43,16 +42,6 @@ extern NoiseParams nparams_v6_def_humidity;
extern NoiseParams nparams_v6_def_trees;
extern NoiseParams nparams_v6_def_apple_trees;
struct Cave {
s16 min_tunnel_diameter;
s16 max_tunnel_diameter;
int dswitchint;
u16 tunnel_routepoints;
int part_max_length_rs;
bool large_cave_is_flat;
bool flooded;
};
struct MapgenV6Params : public MapgenParams {
float freq_desert;
float freq_beach;
@ -166,10 +155,8 @@ public:
void addDirtGravelBlobs();
void growGrass();
void placeTreesAndJungleGrass();
virtual void defineCave(Cave &cave, PseudoRandom ps,
v3s16 node_min, bool large_cave);
void generateCaves(int max_stone_y);
virtual void generateSomething() {}; //for next mapgen
virtual void generateCaves(int max_stone_y);
virtual void generateExperimental() {}
};
struct MapgenFactoryV6 : public MapgenFactory {