summaryrefslogtreecommitdiffstats
path: root/source/Generating/ChunkDesc.h
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-03-17 18:55:03 +0100
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-03-17 18:55:03 +0100
commit1ed3b3aed2e538af2c3bffa41f54a30ac6535f12 (patch)
tree173949d9abcbd08d9c3535704419a372e52c7c8a /source/Generating/ChunkDesc.h
parentProbabDistrib: fixed definition string parsing with nonzero start (diff)
downloadcuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar.gz
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar.bz2
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar.lz
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar.xz
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.tar.zst
cuberite-1ed3b3aed2e538af2c3bffa41f54a30ac6535f12.zip
Diffstat (limited to 'source/Generating/ChunkDesc.h')
-rw-r--r--source/Generating/ChunkDesc.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/source/Generating/ChunkDesc.h b/source/Generating/ChunkDesc.h
index afe3df331..7df7a1d35 100644
--- a/source/Generating/ChunkDesc.h
+++ b/source/Generating/ChunkDesc.h
@@ -33,6 +33,11 @@ public:
// tolua_begin
+ int GetChunkX(void) const { return m_ChunkX; }
+ int GetChunkZ(void) const { return m_ChunkZ; }
+
+ void SetChunkCoords(int a_ChunkX, int a_ChunkZ);
+
void FillBlocks(BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta);
void SetBlockTypeMeta(int a_RelX, int a_RelY, int a_RelZ, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta);
void GetBlockTypeMeta(int a_RelX, int a_RelY, int a_RelZ, BLOCKTYPE & a_BlockType, NIBBLETYPE & a_BlockMeta);
@@ -67,16 +72,19 @@ public:
/// Reads an area from the chunk into a cBlockArea
void ReadBlockArea(cBlockArea & a_Dest, int a_MinRelX, int a_MaxRelX, int a_MinRelY, int a_MaxRelY, int a_MinRelZ, int a_MaxRelZ);
+ /// Returns the maximum height value in the heightmap
+ HEIGHTTYPE GetMaxHeight(void) const;
+
// tolua_end
// Accessors used by cChunkGenerator::Generator descendants:
- cChunkDef::BiomeMap & GetBiomeMap (void) { return m_BiomeMap; }
- cChunkDef::BlockTypes & GetBlockTypes (void) { return m_BlockTypes; }
- cChunkDef::BlockNibbles & GetBlockMetas (void) { return m_BlockMeta; }
- cChunkDef::HeightMap & GetHeightMap (void) { return m_HeightMap; }
- cEntityList & GetEntities (void) { return m_Entities; }
- cBlockEntityList & GetBlockEntities(void) { return m_BlockEntities; }
+ inline cChunkDef::BiomeMap & GetBiomeMap (void) { return m_BiomeMap; }
+ inline cChunkDef::BlockTypes & GetBlockTypes (void) { return m_BlockTypes; }
+ inline cChunkDef::BlockNibbles & GetBlockMetas (void) { return m_BlockMeta; }
+ inline cChunkDef::HeightMap & GetHeightMap (void) { return m_HeightMap; }
+ inline cEntityList & GetEntities (void) { return m_Entities; }
+ inline cBlockEntityList & GetBlockEntities(void) { return m_BlockEntities; }
private:
int m_ChunkX;