diff options
author | Tycho <work.tycho+git@gmail.com> | 2014-05-25 19:02:33 +0200 |
---|---|---|
committer | Tycho <work.tycho+git@gmail.com> | 2014-05-25 19:02:33 +0200 |
commit | 8133efd7f9def01b81ef2a52c05d8ec5b7f89632 (patch) | |
tree | a56f6889aea8de8759fab87abdee2eef778873ed /src/Generating/Ravines.h | |
parent | Fixed bug in freeing NULL pointers (diff) | |
parent | inject TestGlobals.h correctly (diff) | |
download | cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar.gz cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar.bz2 cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar.lz cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar.xz cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.tar.zst cuberite-8133efd7f9def01b81ef2a52c05d8ec5b7f89632.zip |
Diffstat (limited to 'src/Generating/Ravines.h')
-rw-r--r-- | src/Generating/Ravines.h | 24 |
1 files changed, 9 insertions, 15 deletions
diff --git a/src/Generating/Ravines.h b/src/Generating/Ravines.h index c76b9f19f..30b47e9ec 100644 --- a/src/Generating/Ravines.h +++ b/src/Generating/Ravines.h @@ -9,7 +9,7 @@ #pragma once -#include "ComposableGenerator.h" +#include "GridStructGen.h" #include "../Noise.h" @@ -17,28 +17,22 @@ class cStructGenRavines : - public cFinishGen + public cGridStructGen { + typedef cGridStructGen super; + public: cStructGenRavines(int a_Seed, int a_Size); - ~cStructGenRavines(); protected: class cRavine; // fwd: Ravines.cpp - typedef std::list<cRavine *> cRavines; - - cNoise m_Noise; - int m_Size; // Max size, in blocks, of the ravines generated - cRavines m_Cache; - /// Clears everything from the cache - void ClearCache(void); + cNoise m_Noise; + int m_Size; // Max size, in blocks, of the ravines generated - /// Returns all ravines that *may* intersect the given chunk. All the ravines are valid until the next call to this function. - void GetRavinesForChunk(int a_ChunkX, int a_ChunkZ, cRavines & a_Ravines); - - // cFinishGen override: - virtual void GenFinish(cChunkDesc & a_ChunkDesc) override; + + // cGridStructGen overrides: + virtual cStructurePtr CreateStructure(int a_OriginX, int a_OriginZ) override; } ; |