3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-11-03 14:50:30 +01:00

Better fallback for block mismatch

Dieser Commit ist enthalten in:
Myles 2017-12-14 18:45:29 +00:00
Ursprung 77dc403bb9
Commit 616c9474ce

Datei anzeigen

@ -110,7 +110,7 @@ public class WorldPackets {
// TODO: This packet has changed
handler(new PacketHandler() {
@Override
public void handle(PacketWrapper wrapper) throws Exception {
public void handle(PacketWrapper wrapper) {
wrapper.cancel();
}
});
@ -122,7 +122,11 @@ public class WorldPackets {
if (MappingData.oldToNewBlocks.containsKey(oldId)) {
return MappingData.oldToNewBlocks.get(oldId);
} else {
if (MappingData.oldToNewBlocks.containsKey((oldId >> 4) << 4)) {
System.out.println("Missing block " + oldId);
return MappingData.oldToNewBlocks.get((oldId >> 4) << 4);
}
System.out.println("Missing block completely " + oldId);
// Default stone
return 1;
}