summaryrefslogtreecommitdiffstats
path: root/source/WSSCompact.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--source/WSSCompact.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/source/WSSCompact.cpp b/source/WSSCompact.cpp
index ae920e55f..8c27dba51 100644
--- a/source/WSSCompact.cpp
+++ b/source/WSSCompact.cpp
@@ -734,12 +734,14 @@ bool cWSSCompact::LoadChunkFromData(const cChunkCoords & a_Chunk, int & a_Uncomp
}
}
+ BLOCKTYPE * BlockData = (BLOCKTYPE *)UncompressedData.data();
+
a_World->ChunkDataLoaded(
a_Chunk.m_ChunkX, a_Chunk.m_ChunkY, a_Chunk.m_ChunkZ,
- UncompressedData.data(),
- UncompressedData.data() + cChunkDef::MetaOffset,
- UncompressedData.data() + cChunkDef::LightOffset,
- UncompressedData.data() + cChunkDef::SkyLightOffset,
+ BlockData,
+ BlockData + cChunkDef::MetaOffset,
+ BlockData + cChunkDef::LightOffset,
+ BlockData + cChunkDef::SkyLightOffset,
NULL,
Entities,
BlockEntities
@@ -788,7 +790,7 @@ bool cWSSCompact::cPAKFile::SaveChunkToData(const cChunkCoords & a_Chunk, cWorld
}
AString Data;
- Data.assign(Serializer.GetBlockData(), cChunkDef::BlockDataSize);
+ Data.assign((const char *)Serializer.GetBlockData(), cChunkDef::BlockDataSize);
if (Serializer.HasJsonData())
{
AString JsonData;