mirror of
https://github.com/ViaVersion/ViaBackwards.git
synced 2024-11-24 12:35:43 +01:00
Handle bad heightmaps in 1.17->1.16.4 (#743)
This commit is contained in:
parent
6292c5a5a5
commit
1a22b371cd
@ -339,6 +339,10 @@ public final class BlockItemPackets1_17 extends BackwardsItemRewriter<Clientboun
|
||||
|
||||
CompoundTag heightMaps = chunk.getHeightMap();
|
||||
for (Tag heightMapTag : heightMaps.values()) {
|
||||
if (!(heightMapTag instanceof LongArrayTag)) {
|
||||
continue; // Client can handle bad data
|
||||
}
|
||||
|
||||
LongArrayTag heightMap = (LongArrayTag) heightMapTag;
|
||||
int[] heightMapData = new int[256];
|
||||
int bitsPerEntry = MathUtil.ceilLog2((currentWorldSectionHeight << 4) + 1);
|
||||
|
Loading…
Reference in New Issue
Block a user