From be31652c40af10b0410c76c6bd37b60717c385be Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Fri, 23 Mar 2012 21:12:48 +0000 Subject: Encapsulated cWorld functions needed in cWorldStorage into an interface, so that cWorldStorage can actually be used outside of MC-Server (such as storage conversion tools and chunk analyzers) git-svn-id: http://mc-server.googlecode.com/svn/trunk@427 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/WSSCompact.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'source/WSSCompact.h') diff --git a/source/WSSCompact.h b/source/WSSCompact.h index cd753ce9c..a50405d6d 100644 --- a/source/WSSCompact.h +++ b/source/WSSCompact.h @@ -22,7 +22,7 @@ class cWSSCompact : public cWSSchema { public: - cWSSCompact(cWorld * a_World) : cWSSchema(a_World) {} + cWSSCompact(cWSInterface * a_WSI) : cWSSchema(a_WSI) {} virtual ~cWSSCompact(); protected: @@ -42,7 +42,7 @@ protected: bool SetChunkData(const cChunkCoords & a_Chunk, int a_UncompressedSize, const AString & a_Data); bool EraseChunkData(const cChunkCoords & a_Chunk); - bool SaveChunk(const cChunkCoords & a_Chunk, cWorld * a_World); + bool SaveChunk(const cChunkCoords & a_Chunk, cWSInterface * a_WSI); int GetLayerX(void) const {return m_LayerX; } int GetLayerZ(void) const {return m_LayerZ; } @@ -68,7 +68,7 @@ protected: char m_ChunkVersion; char m_PakVersion; - bool SaveChunkToData(const cChunkCoords & a_Chunk, cWorld * a_World); // Saves the chunk to m_DataContents, updates headers and m_NumDirty + bool SaveChunkToData(const cChunkCoords & a_Chunk, cWSInterface * a_WSI); // 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); // Height from 128 to 256 @@ -93,9 +93,9 @@ protected: bool EraseChunkData(const cChunkCoords & a_Chunk); /// Loads the chunk from the data (no locking needed) - bool LoadChunkFromData(const cChunkCoords & a_Chunk, int & a_UncompressedSize, const AString & a_Data, cWorld * a_World); + bool LoadChunkFromData(const cChunkCoords & a_Chunk, int & a_UncompressedSize, const AString & a_Data, cWSInterface * a_WSI); - void LoadEntitiesFromJson(Json::Value & a_Value, cEntityList & a_Entities, cBlockEntityList & a_BlockEntities, cWorld * a_World); + void LoadEntitiesFromJson(Json::Value & a_Value, cEntityList & a_Entities, cBlockEntityList & a_BlockEntities, cWSInterface * a_WSI); // cWSSchema overrides: virtual bool LoadChunk(const cChunkCoords & a_Chunk) override; -- cgit v1.2.3