Content and parameters width seems to be 255 instead of 2 in new block format. This is strange becaus they are set hard to 2 in mapblock.cpp#MapBlock::serialize.

This commit is contained in:
Sascha L. Teichmann 2017-02-24 12:02:06 +01:00
parent 90279506d1
commit c167efecd2
1 changed files with 2 additions and 2 deletions

View File

@ -100,8 +100,8 @@ func NewDecodedBlock(data []byte, colors *Colors) (db *DecodedBlock, err error)
version := data[0]
contentWidth := int(data[2])
paramsWidth := int(data[3])
contentWidth := Min(int(data[2]), 2)
paramsWidth := Min(int(data[3]), 2)
uncompressedLen := nodeCount * (contentWidth + paramsWidth)