Skip to content

Commit

Permalink
Supporting 1.14.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Exceptionflug committed May 30, 2019
1 parent ca3a158 commit e2bf871
Show file tree
Hide file tree
Showing 30 changed files with 958 additions and 942 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,25 @@ This is the full portfolio of protocolize dependencies:
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-api</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-items</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-inventory</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-world</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
```
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>de.exceptionflug</groupId>
<artifactId>protocolize</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<packaging>pom</packaging>

<properties>
Expand Down
2 changes: 1 addition & 1 deletion protocolize-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<parent>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
</parent>

<groupId>de.exceptionflug</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public final class ProtocolVersions {
public final static int MINECRAFT_1_13_2 = 404;
public final static int MINECRAFT_1_14 = 477;
public final static int MINECRAFT_1_14_1 = 480;
public final static int MINECRAFT_1_14_2 = 485;

private ProtocolVersions() {}

Expand Down
8 changes: 4 additions & 4 deletions protocolize-examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
</parent>

<groupId>de.exceptionflug</groupId>
Expand All @@ -18,19 +18,19 @@
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-api</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-items</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-inventory</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
</dependencies>
Expand Down
6 changes: 3 additions & 3 deletions protocolize-inventory/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,18 @@
<parent>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
</parent>

<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-inventory</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>

<dependencies>
<dependency>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-api</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,30 @@

public enum InventoryType {

GENERIC_9X1(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 9), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 0, 9)),
GENERIC_9X2(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 18), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 1, 18)),
GENERIC_9X3(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 27), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 2, 27)),
GENERIC_9X4(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 36), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 3, 36)),
GENERIC_9X5(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 45), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 4, 45)),
GENERIC_9X6(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 54), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 5, 54)),
GENERIC_3X3(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:dropper", 9), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 6, 9)),
ANVIL(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:anvil", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 7, 3)),
BEACON(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:beacon", 1), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 8, 1)),
BLAST_FURNACE(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 9, 2)),
BREWING_STAND(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_8, "minecraft:brewing_stand", 4), new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "minecraft:brewing_stand", 5), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 10, 5)),
CRAFTING(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:crafting_table", 10), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 11, 10)),
ENCHANTMENT(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:enchanting_table", 2), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 12, 2)),
FURNACE(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:furnace", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 13, 3)),
GRINDSTONE(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 14, 3)),
HOPPER(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:hopper", 5), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 15, 5)),
LECTERN(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 16, 0)),
LOOM(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 17, 4)),
MERCHANT(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:villager", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 18, 3)),
SHULKER_BOX(new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "minecraft:shulker_box", 27), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 19, 27)),
SMOKER(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 20, 3)),
CARTOGRAPHY(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 21, 3)),
STONECUTTER(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, 22, 2)),
PLAYER(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_8, "Player", 45), new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "Player", 46), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_1, -1, 46));
GENERIC_9X1(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 9), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 0, 9)),
GENERIC_9X2(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 18), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 1, 18)),
GENERIC_9X3(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 27), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 2, 27)),
GENERIC_9X4(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 36), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 3, 36)),
GENERIC_9X5(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 45), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 4, 45)),
GENERIC_9X6(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:container", 54), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 5, 54)),
GENERIC_3X3(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:dropper", 9), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 6, 9)),
ANVIL(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:anvil", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 7, 3)),
BEACON(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:beacon", 1), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 8, 1)),
BLAST_FURNACE(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 9, 2)),
BREWING_STAND(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_8, "minecraft:brewing_stand", 4), new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "minecraft:brewing_stand", 5), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 10, 5)),
CRAFTING(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:crafting_table", 10), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 11, 10)),
ENCHANTMENT(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:enchanting_table", 2), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 12, 2)),
FURNACE(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:furnace", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 13, 3)),
GRINDSTONE(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 14, 3)),
HOPPER(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:hopper", 5), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 15, 5)),
LECTERN(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 16, 0)),
LOOM(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 17, 4)),
MERCHANT(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_13_2, "minecraft:villager", 3), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 18, 3)),
SHULKER_BOX(new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "minecraft:shulker_box", 27), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 19, 27)),
SMOKER(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 20, 3)),
CARTOGRAPHY(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 21, 3)),
STONECUTTER(new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, 22, 2)),
PLAYER(new InventoryIDMapping(MINECRAFT_1_8, MINECRAFT_1_8, "Player", 45), new InventoryIDMapping(MINECRAFT_1_9, MINECRAFT_1_13_2, "Player", 46), new InventoryIDMapping(MINECRAFT_1_14, MINECRAFT_1_14_2, -1, 46));

private final InventoryIDMapping[] mappings;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public class ClickWindow extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x08);
MAPPING.put(MINECRAFT_1_14, 0x09);
MAPPING.put(MINECRAFT_1_14_1, 0x09);
MAPPING.put(MINECRAFT_1_14_2, 0x09);
}

private int windowId, actionNumber;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public class CloseWindow extends AbstractPacket {
MAPPING_CLIENTBOUND.put(MINECRAFT_1_13_2, 0x13);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14, 0x13);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_1, 0x13);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_2, 0x13);

MAPPING_SERVERBOUND.put(MINECRAFT_1_8, 0x0D);
MAPPING_SERVERBOUND.put(MINECRAFT_1_9, 0x08);
Expand All @@ -49,6 +50,7 @@ public class CloseWindow extends AbstractPacket {
MAPPING_SERVERBOUND.put(MINECRAFT_1_13_2, 0x09);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14, 0x0A);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_1, 0x0A);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_2, 0x0A);
}

private int windowId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ public class ConfirmTransaction extends AbstractPacket {
MAPPING_CLIENTBOUND.put(MINECRAFT_1_13_2, 0x12);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14, 0x12);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_1, 0x12);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_2, 0x12);

MAPPING_SERVERBOUND.put(MINECRAFT_1_9, 0x05);
MAPPING_SERVERBOUND.put(MINECRAFT_1_9_1, 0x05);
Expand All @@ -50,6 +51,7 @@ public class ConfirmTransaction extends AbstractPacket {
MAPPING_SERVERBOUND.put(MINECRAFT_1_13_2, 0x06);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14, 0x07);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_1, 0x07);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_2, 0x07);
}

private int windowId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public class OpenWindow extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x14);
MAPPING.put(MINECRAFT_1_14, 0x2E);
MAPPING.put(MINECRAFT_1_14_1, 0x2E);
MAPPING.put(MINECRAFT_1_14_2, 0x2E);
}

private int windowId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public class WindowProperty extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x16);
MAPPING.put(MINECRAFT_1_14, 0x15);
MAPPING.put(MINECRAFT_1_14_1, 0x15);
MAPPING.put(MINECRAFT_1_14_2, 0x15);
}

private int windowId;
Expand Down
6 changes: 3 additions & 3 deletions protocolize-items/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<plugin>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-protogen-plugin</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
<executions>
<execution>
<phase>generate-sources</phase>
Expand All @@ -33,12 +33,12 @@
<parent>
<groupId>de.exceptionflug</groupId>
<artifactId>protocolize</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>
</parent>

<groupId>de.exceptionflug</groupId>
<artifactId>protocolize-items</artifactId>
<version>1.4.2-SNAPSHOT</version>
<version>1.4.3-SNAPSHOT</version>

<dependencies>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ public class BlockPlacement extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x29);
MAPPING.put(MINECRAFT_1_14, 0x2C);
MAPPING.put(MINECRAFT_1_14_1, 0x2C);
MAPPING.put(MINECRAFT_1_14_2, 0x2C);
}

private BlockPosition position;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public class HeldItemChange extends AbstractPacket {
MAPPING_CLIENTBOUND.put(MINECRAFT_1_13_2, 0x3D);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14, 0x3F);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_1, 0x3F);
MAPPING_CLIENTBOUND.put(MINECRAFT_1_14_2, 0x3F);

MAPPING_SERVERBOUND.put(MINECRAFT_1_8, 0x09);
MAPPING_SERVERBOUND.put(MINECRAFT_1_9, 0x17);
Expand All @@ -49,6 +50,7 @@ public class HeldItemChange extends AbstractPacket {
MAPPING_SERVERBOUND.put(MINECRAFT_1_13_2, 0x21);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14, 0x23);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_1, 0x23);
MAPPING_SERVERBOUND.put(MINECRAFT_1_14_2, 0x23);
}

private short newSlot;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ public class SetSlot extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x17);
MAPPING.put(MINECRAFT_1_14, 0x16);
MAPPING.put(MINECRAFT_1_14_1, 0x16);
MAPPING.put(MINECRAFT_1_14_2, 0x16);
}

private byte windowId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ public class UseItem extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x2A);
MAPPING.put(MINECRAFT_1_14, 0x2D);
MAPPING.put(MINECRAFT_1_14_1, 0x2D);
MAPPING.put(MINECRAFT_1_14_2, 0x2D);
}

private Hand hand;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class WindowItems extends AbstractPacket {
MAPPING.put(MINECRAFT_1_13_2, 0x15);
MAPPING.put(MINECRAFT_1_14, 0x14);
MAPPING.put(MINECRAFT_1_14_1, 0x14);
MAPPING.put(MINECRAFT_1_14_2, 0x14);
}

public WindowItems(final short windowId, final List<ItemStack> items) {
Expand Down
Loading

0 comments on commit e2bf871

Please sign in to comment.