summaryrefslogtreecommitdiffstats
path: root/source/WSSCompact.h
diff options
context:
space:
mode:
authorfaketruth <faketruth@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-03-04 16:59:10 +0100
committerfaketruth <faketruth@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-03-04 16:59:10 +0100
commit95eb3a7bd7a5c3017410b38594aca78387d6caa2 (patch)
tree44d4ad88031a947f6f2a69c1e3a25c95f169e21e /source/WSSCompact.h
parentThe world can now truly be made higher by incrementing cChunk::c_ChunkHeight to 256. !!HOWEVER THIS WILL DESTROY YOUR SAVED WORLD!! (diff)
downloadcuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar.gz
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar.bz2
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar.lz
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar.xz
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.tar.zst
cuberite-95eb3a7bd7a5c3017410b38594aca78387d6caa2.zip
Diffstat (limited to '')
-rw-r--r--source/WSSCompact.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/source/WSSCompact.h b/source/WSSCompact.h
index 1cb8d161b..c42c8c5b9 100644
--- a/source/WSSCompact.h
+++ b/source/WSSCompact.h
@@ -12,6 +12,7 @@
#define WSSCOMPACT_H_INCLUDED
#include "WorldStorage.h"
+#include "Vector3i.h"
@@ -47,6 +48,8 @@ protected:
int GetLayerX(void) const {return m_LayerX; }
int GetLayerZ(void) const {return m_LayerZ; }
+ static const int PAK_VERSION = 1;
+ static const int CHUNK_VERSION = 2;
protected:
AString m_FileName;
@@ -57,10 +60,16 @@ protected:
AString m_DataContents; // Data contents of the file, cached
int m_NumDirty; // Number of chunks that were written into m_DataContents but not into the file
+
+ Vector3i m_ChunkSize; // Is related to m_ChunkVersion
+ char m_ChunkVersion;
+ char m_PakVersion;
bool LoadChunk(const cChunkCoords & a_Chunk, int a_Offset, sChunkHeader * a_Header, cWorld * a_World);
bool SaveChunkToData(const cChunkCoords & a_Chunk, cWorld * a_World); // Saves the chunk to m_DataContents, updates headers and m_NumDirty
void SynchronizeFile(void); // Writes m_DataContents along with the headers to file, resets m_NumDirty
+
+ void UpdateChunk1To2(void);
} ;
typedef std::list<cPAKFile *> cPAKFiles;