From 859141a0ce38fbd606d95ae7a2f0999acf2fbe84 Mon Sep 17 00:00:00 2001 From: paramat Date: Sun, 12 Mar 2017 13:26:09 +0000 Subject: Cavegen/Mgv5/Mgv7: Add optional giant caverns 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. --- src/mapgen_v5.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/mapgen_v5.h') diff --git a/src/mapgen_v5.h b/src/mapgen_v5.h index ddb090a9c..034d53560 100644 --- a/src/mapgen_v5.h +++ b/src/mapgen_v5.h @@ -25,6 +25,9 @@ with this program; if not, write to the Free Software Foundation, Inc., #define MGV5_LARGE_CAVE_DEPTH -256 +///////// Mapgen V5 flags +#define MGV5_CAVERNS 0x01 + class BiomeManager; extern FlagDesc flagdesc_mapgen_v5[]; @@ -33,12 +36,17 @@ extern FlagDesc flagdesc_mapgen_v5[]; struct MapgenV5Params : public MapgenParams { u32 spflags; float cave_width; + s16 cavern_limit; + s16 cavern_taper; + float cavern_threshold; + NoiseParams np_filler_depth; NoiseParams np_factor; NoiseParams np_height; + NoiseParams np_ground; NoiseParams np_cave1; NoiseParams np_cave2; - NoiseParams np_ground; + NoiseParams np_cavern; MapgenV5Params(); ~MapgenV5Params() {} -- cgit v1.2.3 From 91a9382c25328075d1a27593b22b0a75863951e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Blot?= Date: Sun, 23 Apr 2017 09:52:40 +0200 Subject: Pass clang-format on various cpp/header files (#5559) --- src/mapgen_v5.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/mapgen_v5.h') diff --git a/src/mapgen_v5.h b/src/mapgen_v5.h index 034d53560..1cdb33683 100644 --- a/src/mapgen_v5.h +++ b/src/mapgen_v5.h @@ -32,8 +32,8 @@ class BiomeManager; extern FlagDesc flagdesc_mapgen_v5[]; - -struct MapgenV5Params : public MapgenParams { +struct MapgenV5Params : public MapgenParams +{ u32 spflags; float cave_width; s16 cavern_limit; @@ -55,8 +55,8 @@ struct MapgenV5Params : public MapgenParams { void writeParams(Settings *settings) const; }; - -class MapgenV5 : public MapgenBasic { +class MapgenV5 : public MapgenBasic +{ public: MapgenV5(int mapgenid, MapgenV5Params *params, EmergeManager *emerge); ~MapgenV5(); -- cgit v1.2.3 From 210a339dce754a6cb03d4ef82f5bacc80b63262b Mon Sep 17 00:00:00 2001 From: paramat Date: Thu, 25 May 2017 18:53:47 +0100 Subject: Mapgen files: Update and correct copyright credits --- src/mapgen_v5.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mapgen_v5.h') diff --git a/src/mapgen_v5.h b/src/mapgen_v5.h index 1cdb33683..b742638cd 100644 --- a/src/mapgen_v5.h +++ b/src/mapgen_v5.h @@ -1,7 +1,7 @@ /* Minetest -Copyright (C) 2010-2015 kwolekr, Ryan Kwolek -Copyright (C) 2010-2015 paramat, Matt Gregory +Copyright (C) 2014-2017 paramat +Copyright (C) 2014-2016 kwolekr, Ryan Kwolek This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -- cgit v1.2.3