diff options
Diffstat (limited to 'Tools/AnvilStats/HeightMap.h')
-rw-r--r-- | Tools/AnvilStats/HeightMap.h | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/Tools/AnvilStats/HeightMap.h b/Tools/AnvilStats/HeightMap.h index 69deb5bab..9d62febfc 100644 --- a/Tools/AnvilStats/HeightMap.h +++ b/Tools/AnvilStats/HeightMap.h @@ -15,17 +15,16 @@ -class cHeightMap : - public cCallback +class cHeightMap : public cCallback { -public: + public: cHeightMap(void); void Finish(void); static bool IsGround(BLOCKTYPE a_BlockType); -protected: + protected: int m_CurrentChunkX; // Absolute chunk coords int m_CurrentChunkZ; int m_CurrentChunkOffX; // Chunk offset from the start of the region @@ -34,18 +33,24 @@ protected: int m_CurrentRegionZ; bool m_IsCurrentRegionValid; /** Height-map of the entire current region [x + 16 * 32 * z] */ - int m_Height[16 * 32 * 16 * 32]; + int m_Height[16 * 32 * 16 * 32]; /** Block data of the currently processed chunk (between OnSection() and OnSectionsFinished()) */ BLOCKTYPE m_BlockTypes[16 * 16 * 256]; // cCallback overrides: virtual bool OnNewChunk(int a_ChunkX, int a_ChunkZ) override; virtual bool OnHeader(int a_FileOffset, unsigned char a_NumSectors, int a_Timestamp) override { return false; } - virtual bool OnCompressedDataSizePos(int a_CompressedDataSize, int a_DataOffset, char a_CompressionMethod) override { return false; } + virtual bool OnCompressedDataSizePos(int a_CompressedDataSize, int a_DataOffset, char a_CompressionMethod) override + { + return false; + } virtual bool OnDecompressedData(const char * a_DecompressedNBT, int a_DataSize) override { return false; } virtual bool OnRealCoords(int a_ChunkX, int a_ChunkZ) override { return false; } virtual bool OnLastUpdate(Int64 a_LastUpdate) override { return false; } - virtual bool OnTerrainPopulated(bool a_Populated) override { return !a_Populated; } // If not populated, we don't want it! + virtual bool OnTerrainPopulated(bool a_Populated) override + { + return !a_Populated; + } // If not populated, we don't want it! virtual bool OnBiomes(const unsigned char * a_BiomeData) { return false; } virtual bool OnHeightMap(const int * a_HeightMapBE) override; virtual bool OnSection( @@ -59,21 +64,16 @@ protected: virtual bool OnSectionsFinished(void) override; void StartNewRegion(int a_RegionX, int a_RegionZ); -} ; +}; -class cHeightMapFactory : - public cCallbackFactory +class cHeightMapFactory : public cCallbackFactory { -public: + public: virtual ~cHeightMapFactory(); - virtual cCallback * CreateNewCallback(void) override - { - return new cHeightMap; - } - -} ; + virtual cCallback * CreateNewCallback(void) override { return new cHeightMap; } +}; |