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

Fix block remaps

Dieser Commit ist enthalten in:
KennyTV 2019-06-02 00:00:38 +02:00
Ursprung c2d72214de
Commit 0084f764ba
3 geänderte Dateien mit 3 neuen und 3 gelöschten Zeilen

Datei anzeigen

@ -280,7 +280,7 @@ public class Protocol1_13_2To1_14 extends BackwardsProtocol {
int newId = BackwardsMappings.blockMappings.getNewBlock(id); int newId = BackwardsMappings.blockMappings.getNewBlock(id);
if (newId == -1) { if (newId == -1) {
ViaBackwards.getPlatform().getLogger().warning("Missing 1.14 block id for 1.13.2 block " + id); ViaBackwards.getPlatform().getLogger().warning("Missing 1.14 block id for 1.13.2 block " + id);
return 0; return id;
} }
return newId; return newId;
} }

Datei anzeigen

@ -24,7 +24,7 @@ public class BackwardsMappings {
ViaBackwards.getPlatform().getLogger().info("Loading 1.14 -> 1.13.2 block mapping..."); ViaBackwards.getPlatform().getLogger().info("Loading 1.14 -> 1.13.2 block mapping...");
blockStateMappings = new BlockMappingsShortArray(mapping1_14.getAsJsonObject("blockstates"), mapping1_13_2.getAsJsonObject("blockstates"), mapping1_13_2to1_14.getAsJsonObject("blockstates")); blockStateMappings = new BlockMappingsShortArray(mapping1_14.getAsJsonObject("blockstates"), mapping1_13_2.getAsJsonObject("blockstates"), mapping1_13_2to1_14.getAsJsonObject("blockstates"));
blockMappings = new BlockMappingsShortArray(mapping1_14.getAsJsonObject("blocks"), mapping1_13_2.getAsJsonObject("blocks"), mapping1_13_2to1_14.getAsJsonObject("blocks")); //blockMappings = new BlockMappingsShortArray(mapping1_14.getAsJsonObject("blocks"), mapping1_13_2.getAsJsonObject("blocks"), mapping1_13_2to1_14.getAsJsonObject("blocks"));
} }

Datei anzeigen

@ -449,7 +449,7 @@ public class BlockItemPackets1_14 extends BlockItemRewriter<Protocol1_13_2To1_14
handler(new PacketHandler() { handler(new PacketHandler() {
@Override @Override
public void handle(PacketWrapper wrapper) throws Exception { public void handle(PacketWrapper wrapper) throws Exception {
wrapper.set(Type.VAR_INT, 0, Protocol1_13_2To1_14.getNewBlockId(wrapper.get(Type.VAR_INT, 0))); wrapper.set(Type.VAR_INT, 0, Protocol1_13_2To1_14.getNewBlockStateId(wrapper.get(Type.VAR_INT, 0))); //TODO proper block id
} }
}); });
} }