diff options
author | Howaner <franzi.moos@googlemail.com> | 2014-09-24 15:17:20 +0200 |
---|---|---|
committer | Howaner <franzi.moos@googlemail.com> | 2014-09-24 15:17:20 +0200 |
commit | 1d588b5195507f52c25d57a627c3304c024770ce (patch) | |
tree | 7d8e0f404ae062a37049e9532e2dceb9ae5ddb09 /src/WorldStorage/NBTChunkSerializer.cpp | |
parent | Merge branch 'master' into WorldLoader (diff) | |
download | cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar.gz cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar.bz2 cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar.lz cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar.xz cuberite-1d588b5195507f52c25d57a627c3304c024770ce.tar.zst cuberite-1d588b5195507f52c25d57a627c3304c024770ce.zip |
Diffstat (limited to 'src/WorldStorage/NBTChunkSerializer.cpp')
-rw-r--r-- | src/WorldStorage/NBTChunkSerializer.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/WorldStorage/NBTChunkSerializer.cpp b/src/WorldStorage/NBTChunkSerializer.cpp index 0e364d8b0..a052bf5f3 100644 --- a/src/WorldStorage/NBTChunkSerializer.cpp +++ b/src/WorldStorage/NBTChunkSerializer.cpp @@ -81,6 +81,18 @@ void cNBTChunkSerializer::Finish(void) memset(m_BlockLight, 0, sizeof(m_BlockLight)); memset(m_BlockSkyLight, 0, sizeof(m_BlockSkyLight)); } + + // Check if "Entity" and "TileEntities" lists exists. MCEdit requires this. + if (!m_HasHadEntity) + { + a_Writer.BeginList("Entities", TAG_Compound); + a_Writer.EndList(); + } + if (!m_HasHadBlockEntity) + { + a_Writer.BeginList("TileEntities", TAG_Compound); + a_Writer.EndList(); + } } |