it's not zipping correctly; some fixes on readlayer

This commit is contained in:
minjaesong
2018-10-05 01:11:12 +09:00
parent 374070e9b9
commit 1d67a9a9ce
8 changed files with 92 additions and 23 deletions

View File

@@ -100,6 +100,9 @@ internal object WriteLayerDataZip {
outputStream.flush()
// TERR payload
// PRO Debug tip: every deflated bytes must begin with 0x789C or 0x78DA
// Thus, \0pLd + [10] must be either of these.
wb(PAYLOAD_HEADER); wb("TERR".toByteArray())
wi48(world.width * world.height * 3L / 2)
deflater.write(world.terrainArray)