Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-26 16:12:42 +01:00
Better fallback for block mismatch
Dieser Commit ist enthalten in:
Ursprung
77dc403bb9
Commit
616c9474ce
@ -110,7 +110,7 @@ public class WorldPackets {
|
|||||||
// TODO: This packet has changed
|
// TODO: This packet has changed
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@Override
|
@Override
|
||||||
public void handle(PacketWrapper wrapper) throws Exception {
|
public void handle(PacketWrapper wrapper) {
|
||||||
wrapper.cancel();
|
wrapper.cancel();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -122,7 +122,11 @@ public class WorldPackets {
|
|||||||
if (MappingData.oldToNewBlocks.containsKey(oldId)) {
|
if (MappingData.oldToNewBlocks.containsKey(oldId)) {
|
||||||
return MappingData.oldToNewBlocks.get(oldId);
|
return MappingData.oldToNewBlocks.get(oldId);
|
||||||
} else {
|
} else {
|
||||||
System.out.println("Missing block " + oldId);
|
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
|
// Default stone
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren