diff options
author | kwolekr <kwolekr@minetest.net> | 2014-02-03 22:42:10 -0500 |
---|---|---|
committer | kwolekr <kwolekr@minetest.net> | 2014-02-03 22:50:14 -0500 |
commit | 5a34f40d80ea1a339b599bc11db549a6bd86912f (patch) | |
tree | 07ead9e3ff4732479af41b739a26b5dc8182c5fd /src/noise.h | |
parent | a439343844cf821e4922e23f1638b92e2cfb14ac (diff) | |
download | minetest-5a34f40d80ea1a339b599bc11db549a6bd86912f.tar.gz minetest-5a34f40d80ea1a339b599bc11db549a6bd86912f.tar.bz2 minetest-5a34f40d80ea1a339b599bc11db549a6bd86912f.zip |
Huge overhaul of the entire MapgenParams system
MapgenParams is no longer a polymorphic class, eliminating the need for messy and bug-prone reallocations.
Separation between the common and mapgen-specific parameters is now strongly defined.
Mapgen parameters objects are now properly encapsulated within the proper subsystems.
Diffstat (limited to 'src/noise.h')
-rw-r--r-- | src/noise.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/noise.h b/src/noise.h index 0bf1a2f13..074bedb92 100644 --- a/src/noise.h +++ b/src/noise.h @@ -68,6 +68,19 @@ struct NoiseParams { int seed; int octaves; float persist; + + NoiseParams() {} + + NoiseParams(float offset_, float scale_, v3f spread_, + int seed_, int octaves_, float persist_) + { + offset = offset_; + scale = scale_; + spread = spread_; + seed = seed_; + octaves = octaves_; + persist = persist_; + } }; |