summaryrefslogtreecommitdiffstats
path: root/src/WorldStorage
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-04-26 23:26:59 +0200
committerMattes D <github@xoft.cz>2014-04-26 23:26:59 +0200
commitda931da6037279826a52980f9335e189c370d4d2 (patch)
tree2935aeea2eab9d1ce7dbf571087d905a4681fae3 /src/WorldStorage
parentMerge pull request #863 from mc-server/chunkysparsing (diff)
parentMore small fixes. (diff)
downloadcuberite-da931da6037279826a52980f9335e189c370d4d2.tar
cuberite-da931da6037279826a52980f9335e189c370d4d2.tar.gz
cuberite-da931da6037279826a52980f9335e189c370d4d2.tar.bz2
cuberite-da931da6037279826a52980f9335e189c370d4d2.tar.lz
cuberite-da931da6037279826a52980f9335e189c370d4d2.tar.xz
cuberite-da931da6037279826a52980f9335e189c370d4d2.tar.zst
cuberite-da931da6037279826a52980f9335e189c370d4d2.zip
Diffstat (limited to 'src/WorldStorage')
-rw-r--r--src/WorldStorage/NBTChunkSerializer.cpp8
-rw-r--r--src/WorldStorage/WSSCompact.cpp1
2 files changed, 4 insertions, 5 deletions
diff --git a/src/WorldStorage/NBTChunkSerializer.cpp b/src/WorldStorage/NBTChunkSerializer.cpp
index b6c14db9c..773954f73 100644
--- a/src/WorldStorage/NBTChunkSerializer.cpp
+++ b/src/WorldStorage/NBTChunkSerializer.cpp
@@ -621,10 +621,10 @@ void cNBTChunkSerializer::AddHangingEntity(cHangingEntity * a_Hanging)
m_Writer.AddInt("TileZ", a_Hanging->GetTileZ());
switch (a_Hanging->GetDirection())
{
- case 0: m_Writer.AddByte("Dir", (unsigned char)2); break;
- case 1: m_Writer.AddByte("Dir", (unsigned char)1); break;
- case 2: m_Writer.AddByte("Dir", (unsigned char)0); break;
- case 3: m_Writer.AddByte("Dir", (unsigned char)3); break;
+ case BLOCK_FACE_YM: m_Writer.AddByte("Dir", (unsigned char)2); break;
+ case BLOCK_FACE_YP: m_Writer.AddByte("Dir", (unsigned char)1); break;
+ case BLOCK_FACE_ZM: m_Writer.AddByte("Dir", (unsigned char)0); break;
+ case BLOCK_FACE_ZP: m_Writer.AddByte("Dir", (unsigned char)3); break;
}
}
diff --git a/src/WorldStorage/WSSCompact.cpp b/src/WorldStorage/WSSCompact.cpp
index 5435e6d5a..c07c9e96f 100644
--- a/src/WorldStorage/WSSCompact.cpp
+++ b/src/WorldStorage/WSSCompact.cpp
@@ -797,7 +797,6 @@ void cWSSCompact::cPAKFile::UpdateChunk2To3()
++index2;
}
InChunkOffset += index2 / 2;
- index2 = 0;
AString Converted(ConvertedData, ExpectedSize);