mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 19:15:32 +01:00
Fix mapping of ChunkSection nibble data to snapshot. Fixes BUKKIT-1977
This commit is contained in:
parent
35a3d701a9
commit
c711827e94
@ -183,8 +183,8 @@ public class CraftChunk implements Chunk {
|
||||
continue;
|
||||
}
|
||||
|
||||
blockids[j<<1] |= (b & 0xF0) << 4;
|
||||
blockids[(j<<1)+1] |= (b & 0x0F) << 8;
|
||||
blockids[j<<1] |= (b & 0x0F) << 8;
|
||||
blockids[(j<<1)+1] |= (b & 0xF0) << 4;
|
||||
}
|
||||
}
|
||||
|
||||
@ -192,11 +192,11 @@ public class CraftChunk implements Chunk {
|
||||
|
||||
/* Get block data nibbles */
|
||||
sectionBlockData[i] = new byte[2048];
|
||||
System.arraycopy(cs[i].i().a, 0, sectionBlockData[i], 0, 2048);
|
||||
System.arraycopy(cs[i].j().a, 0, sectionBlockData[i], 0, 2048); // Should be getData
|
||||
sectionSkyLights[i] = new byte[2048];
|
||||
System.arraycopy(cs[i].k().a, 0, sectionSkyLights[i], 0, 2048);
|
||||
System.arraycopy(cs[i].l().a, 0, sectionSkyLights[i], 0, 2048); // Should be getSkyLight
|
||||
sectionEmitLights[i] = new byte[2048];
|
||||
System.arraycopy(cs[i].j().a, 0, sectionEmitLights[i], 0, 2048);
|
||||
System.arraycopy(cs[i].k().a, 0, sectionEmitLights[i], 0, 2048); // Should be getBlockLight
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user