Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-11-03 14:50:30 +01:00
Merge pull request #850 from creeper123123321/dev
1.13-pre7 + Sponge tab-completion fix
Dieser Commit ist enthalten in:
Commit
c88face33e
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
@ -62,7 +62,7 @@ public class ProtocolVersion {
|
|||||||
register(v1_12 = new ProtocolVersion(335, "1.12"));
|
register(v1_12 = new ProtocolVersion(335, "1.12"));
|
||||||
register(v1_12_1 = new ProtocolVersion(338, "1.12.1"));
|
register(v1_12_1 = new ProtocolVersion(338, "1.12.1"));
|
||||||
register(v1_12_2 = new ProtocolVersion(340, "1.12.2"));
|
register(v1_12_2 = new ProtocolVersion(340, "1.12.2"));
|
||||||
register(v1_13 = new ProtocolVersion(388, "1.13-pre6"));
|
register(v1_13 = new ProtocolVersion(389, "1.13-pre7"));
|
||||||
register(unknown = new ProtocolVersion(-1, "UNKNOWN"));
|
register(unknown = new ProtocolVersion(-1, "UNKNOWN"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,6 +88,7 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
|
|
||||||
registerOutgoing(State.PLAY, 0xF, 0xE);
|
registerOutgoing(State.PLAY, 0xF, 0xE);
|
||||||
|
// WorldPackets 0x10 -> 0x0F
|
||||||
|
|
||||||
// Tab-Complete
|
// Tab-Complete
|
||||||
registerOutgoing(State.PLAY, 0xE, 0x10, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0xE, 0x10, new PacketRemapper() {
|
||||||
@ -135,22 +136,23 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
registerOutgoing(State.PLAY, 0x11, 0x12);
|
registerOutgoing(State.PLAY, 0x11, 0x12);
|
||||||
registerOutgoing(State.PLAY, 0x12, 0x13);
|
registerOutgoing(State.PLAY, 0x12, 0x13);
|
||||||
registerOutgoing(State.PLAY, 0x13, 0x14);
|
registerOutgoing(State.PLAY, 0x13, 0x14);
|
||||||
|
// InventoryPackets 0x14 -> 0x15
|
||||||
registerOutgoing(State.PLAY, 0x15, 0x16);
|
registerOutgoing(State.PLAY, 0x15, 0x16);
|
||||||
|
// InventoryPackets 0x16 -> 0x17
|
||||||
registerOutgoing(State.PLAY, 0x17, 0x18);
|
registerOutgoing(State.PLAY, 0x17, 0x18);
|
||||||
|
// InventoryPackets 0x18 -> 0x19
|
||||||
registerOutgoing(State.PLAY, 0x1A, 0x1B);
|
registerOutgoing(State.PLAY, 0x1A, 0x1B);
|
||||||
registerOutgoing(State.PLAY, 0x1B, 0x1C);
|
registerOutgoing(State.PLAY, 0x1B, 0x1C);
|
||||||
registerOutgoing(State.PLAY, 0x1C, 0x1D);
|
// New packet 0x1D - NBT Query
|
||||||
registerOutgoing(State.PLAY, 0x1D, 0x1E);
|
registerOutgoing(State.PLAY, 0x1C, 0x1E);
|
||||||
registerOutgoing(State.PLAY, 0x1E, 0x1F);
|
registerOutgoing(State.PLAY, 0x1D, 0x1F);
|
||||||
registerOutgoing(State.PLAY, 0x1F, 0x20);
|
registerOutgoing(State.PLAY, 0x1E, 0x20);
|
||||||
|
registerOutgoing(State.PLAY, 0x1F, 0x21);
|
||||||
registerOutgoing(State.PLAY, 0x21, 0x22);
|
// WorldPackets 0x20 -> 0x22
|
||||||
|
registerOutgoing(State.PLAY, 0x21, 0x23);
|
||||||
|
// WorldPackets 0x22 -> 0x24
|
||||||
// Join (save dimension id)
|
// Join (save dimension id)
|
||||||
registerOutgoing(State.PLAY, 0x23, 0x24, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x23, 0x25, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.INT); // 0 - Entity ID
|
map(Type.INT); // 0 - Entity ID
|
||||||
@ -192,7 +194,7 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}).send(ProtocolSnapshotTo1_12_2.class);
|
}).send(ProtocolSnapshotTo1_12_2.class);
|
||||||
|
|
||||||
// Send tags packet
|
// Send tags packet
|
||||||
wrapper.create(0x54, new ValueCreator() {
|
wrapper.create(0x55, new ValueCreator() {
|
||||||
@Override
|
@Override
|
||||||
public void write(PacketWrapper wrapper) throws Exception {
|
public void write(PacketWrapper wrapper) throws Exception {
|
||||||
wrapper.write(Type.VAR_INT, MappingData.blockTags.size()); // block tags
|
wrapper.write(Type.VAR_INT, MappingData.blockTags.size()); // block tags
|
||||||
@ -227,7 +229,7 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Map packet
|
// Map packet
|
||||||
registerOutgoing(State.PLAY, 0x24, 0x25, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x24, 0x26, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT); // 0 - Map id
|
map(Type.VAR_INT); // 0 - Map id
|
||||||
@ -251,14 +253,14 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerOutgoing(State.PLAY, 0x25, 0x26);
|
registerOutgoing(State.PLAY, 0x25, 0x27);
|
||||||
registerOutgoing(State.PLAY, 0x26, 0x27);
|
registerOutgoing(State.PLAY, 0x26, 0x28);
|
||||||
registerOutgoing(State.PLAY, 0x27, 0x28);
|
registerOutgoing(State.PLAY, 0x27, 0x29);
|
||||||
registerOutgoing(State.PLAY, 0x28, 0x29);
|
registerOutgoing(State.PLAY, 0x28, 0x2A);
|
||||||
registerOutgoing(State.PLAY, 0x29, 0x2A);
|
registerOutgoing(State.PLAY, 0x29, 0x2B);
|
||||||
registerOutgoing(State.PLAY, 0x2A, 0x2B);
|
registerOutgoing(State.PLAY, 0x2A, 0x2C);
|
||||||
// Craft recipe response
|
// Craft recipe response
|
||||||
registerOutgoing(State.PLAY, 0x2B, 0x2C, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x2B, 0x2D, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -270,13 +272,14 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerOutgoing(State.PLAY, 0x2C, 0x2D);
|
registerOutgoing(State.PLAY, 0x2C, 0x2E);
|
||||||
registerOutgoing(State.PLAY, 0x2D, 0x2E);
|
registerOutgoing(State.PLAY, 0x2D, 0x2F);
|
||||||
registerOutgoing(State.PLAY, 0x2E, 0x2F);
|
registerOutgoing(State.PLAY, 0x2E, 0x30);
|
||||||
registerOutgoing(State.PLAY, 0x2F, 0x31);
|
// New 0x31 - Face Player
|
||||||
registerOutgoing(State.PLAY, 0x30, 0x32);
|
registerOutgoing(State.PLAY, 0x2F, 0x32);
|
||||||
|
registerOutgoing(State.PLAY, 0x30, 0x33);
|
||||||
// Recipe
|
// Recipe
|
||||||
registerOutgoing(State.PLAY, 0x31, 0x33, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x31, 0x34, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -289,11 +292,12 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerOutgoing(State.PLAY, 0x33, 0x35);
|
// EntityPackets 0x32 -> 0x35
|
||||||
registerOutgoing(State.PLAY, 0x34, 0x36);
|
registerOutgoing(State.PLAY, 0x33, 0x36);
|
||||||
|
registerOutgoing(State.PLAY, 0x34, 0x37);
|
||||||
|
|
||||||
// Respawn (save dimension id)
|
// Respawn (save dimension id)
|
||||||
registerOutgoing(State.PLAY, 0x35, 0x37, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x35, 0x38, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.INT); // 0 - Dimension ID
|
map(Type.INT); // 0 - Dimension ID
|
||||||
@ -308,20 +312,20 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerOutgoing(State.PLAY, 0x36, 0x38);
|
registerOutgoing(State.PLAY, 0x36, 0x39);
|
||||||
registerOutgoing(State.PLAY, 0x37, 0x39);
|
registerOutgoing(State.PLAY, 0x37, 0x3A);
|
||||||
registerOutgoing(State.PLAY, 0x38, 0x3A);
|
registerOutgoing(State.PLAY, 0x38, 0x3B);
|
||||||
registerOutgoing(State.PLAY, 0x39, 0x3B);
|
registerOutgoing(State.PLAY, 0x39, 0x3C);
|
||||||
registerOutgoing(State.PLAY, 0x3A, 0x3C);
|
registerOutgoing(State.PLAY, 0x3A, 0x3D);
|
||||||
registerOutgoing(State.PLAY, 0x3B, 0x3D);
|
registerOutgoing(State.PLAY, 0x3B, 0x3E);
|
||||||
|
// EntityPackets 0x3C -> 0x3F
|
||||||
registerOutgoing(State.PLAY, 0x3D, 0x3F);
|
registerOutgoing(State.PLAY, 0x3D, 0x40);
|
||||||
registerOutgoing(State.PLAY, 0x3E, 0x40);
|
registerOutgoing(State.PLAY, 0x3E, 0x41);
|
||||||
|
// InventoryPackets 0x3F -> 0x42
|
||||||
registerOutgoing(State.PLAY, 0x40, 0x42);
|
registerOutgoing(State.PLAY, 0x40, 0x43);
|
||||||
registerOutgoing(State.PLAY, 0x41, 0x43);
|
registerOutgoing(State.PLAY, 0x41, 0x44);
|
||||||
// Scoreboard Objective
|
// Scoreboard Objective
|
||||||
registerOutgoing(State.PLAY, 0x42, 0x44, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x42, 0x45, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.STRING); // 0 - Objective name
|
map(Type.STRING); // 0 - Objective name
|
||||||
@ -342,9 +346,9 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerOutgoing(State.PLAY, 0x43, 0x45);
|
registerOutgoing(State.PLAY, 0x43, 0x46);
|
||||||
// Team packet
|
// Team packet
|
||||||
registerOutgoing(State.PLAY, 0x44, 0x46, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x44, 0x47, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.STRING); // 0 - Team Name
|
map(Type.STRING); // 0 - Team Name
|
||||||
@ -382,13 +386,14 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerOutgoing(State.PLAY, 0x45, 0x47);
|
registerOutgoing(State.PLAY, 0x45, 0x48);
|
||||||
registerOutgoing(State.PLAY, 0x46, 0x48);
|
registerOutgoing(State.PLAY, 0x46, 0x49);
|
||||||
registerOutgoing(State.PLAY, 0x47, 0x49);
|
registerOutgoing(State.PLAY, 0x47, 0x4A);
|
||||||
registerOutgoing(State.PLAY, 0x48, 0x4A);
|
registerOutgoing(State.PLAY, 0x48, 0x4B);
|
||||||
|
// New 0x4C - Stop Sound
|
||||||
|
|
||||||
// Sound Effect packet
|
// Sound Effect packet
|
||||||
registerOutgoing(State.PLAY, 0x49, 0x4C, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x49, 0x4D, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT); // 0 - Sound ID
|
map(Type.VAR_INT); // 0 - Sound ID
|
||||||
@ -402,11 +407,11 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerOutgoing(State.PLAY, 0x4A, 0x4D);
|
registerOutgoing(State.PLAY, 0x4A, 0x4E);
|
||||||
registerOutgoing(State.PLAY, 0x4B, 0x4E);
|
registerOutgoing(State.PLAY, 0x4B, 0x4F);
|
||||||
registerOutgoing(State.PLAY, 0x4C, 0x4F);
|
registerOutgoing(State.PLAY, 0x4C, 0x50);
|
||||||
// Advancements
|
// Advancements
|
||||||
registerOutgoing(State.PLAY, 0x4D, 0x50, new PacketRemapper() {
|
registerOutgoing(State.PLAY, 0x4D, 0x51, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -418,10 +423,10 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerOutgoing(State.PLAY, 0x4E, 0x51);
|
registerOutgoing(State.PLAY, 0x4E, 0x52);
|
||||||
registerOutgoing(State.PLAY, 0x4F, 0x52);
|
registerOutgoing(State.PLAY, 0x4F, 0x53);
|
||||||
// New packet 0x52 - Declare Recipes
|
// New packet 0x54 - Declare Recipes
|
||||||
// New packet 0x53 - Tags
|
// New packet 0x55 - Tags
|
||||||
|
|
||||||
// Incoming packets
|
// Incoming packets
|
||||||
|
|
||||||
@ -440,12 +445,21 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
registerIncoming(State.LOGIN, 0x0, 0x1);
|
registerIncoming(State.LOGIN, 0x0, 0x1);
|
||||||
registerIncoming(State.LOGIN, 0x1, 0x2);
|
registerIncoming(State.LOGIN, 0x1, 0x2);
|
||||||
|
|
||||||
registerIncoming(State.PLAY, 0x2, 0x1);
|
// New 0x01 - Query Block NBT
|
||||||
registerIncoming(State.PLAY, 0x3, 0x2);
|
registerIncoming(State.PLAY, -1, 0x01, new PacketRemapper() {
|
||||||
registerIncoming(State.PLAY, 0x4, 0x3);
|
@Override
|
||||||
|
public void registerMap() {
|
||||||
|
handler(new PacketHandler() {
|
||||||
|
@Override
|
||||||
|
public void handle(PacketWrapper wrapper) throws Exception {
|
||||||
|
wrapper.cancel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
// Tab-Complete
|
// Tab-Complete
|
||||||
registerIncoming(State.PLAY, 0x1, 0x4, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x1, 0x5, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -475,8 +489,14 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
registerIncoming(State.PLAY, 0x05, 0x06);
|
||||||
|
registerIncoming(State.PLAY, 0x06, 0x07);
|
||||||
|
registerIncoming(State.PLAY, 0x07, 0x08);
|
||||||
|
registerIncoming(State.PLAY, 0x08, 0x09);
|
||||||
|
|
||||||
|
// InventoryPackets 0x09 -> 0x0A
|
||||||
// New 0x0A - Edit book -> Plugin Message
|
// New 0x0A - Edit book -> Plugin Message
|
||||||
registerIncoming(State.PLAY, 0x09, 0x0a, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x0B, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -493,16 +513,28 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
registerIncoming(State.PLAY, 0x0b, 0x0c);
|
// New 0x0C - Query Entity NBT
|
||||||
registerIncoming(State.PLAY, 0x0A, 0x0B);
|
registerIncoming(State.PLAY, -1, 0x0C, new PacketRemapper() {
|
||||||
registerIncoming(State.PLAY, 0x0c, 0x0d);
|
@Override
|
||||||
registerIncoming(State.PLAY, 0x0d, 0x0e);
|
public void registerMap() {
|
||||||
registerIncoming(State.PLAY, 0x0e, 0x0f);
|
handler(new PacketHandler() {
|
||||||
registerIncoming(State.PLAY, 0x0f, 0x10);
|
@Override
|
||||||
registerIncoming(State.PLAY, 0x10, 0x11);
|
public void handle(PacketWrapper wrapper) throws Exception {
|
||||||
registerIncoming(State.PLAY, 0x11, 0x12);
|
wrapper.cancel();
|
||||||
// New 0x13 - Pick Item -> Plugin Message
|
}
|
||||||
registerIncoming(State.PLAY, 0x09, 0x13, new PacketRemapper() {
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
registerIncoming(State.PLAY, 0x0A, 0x0D);
|
||||||
|
registerIncoming(State.PLAY, 0x0B, 0x0E);
|
||||||
|
registerIncoming(State.PLAY, 0x0C, 0x0F);
|
||||||
|
registerIncoming(State.PLAY, 0x0D, 0x10);
|
||||||
|
registerIncoming(State.PLAY, 0x0E, 0x11);
|
||||||
|
registerIncoming(State.PLAY, 0x0F, 0x12);
|
||||||
|
registerIncoming(State.PLAY, 0x10, 0x13);
|
||||||
|
registerIncoming(State.PLAY, 0x11, 0x14);
|
||||||
|
// New 0x15 - Pick Item -> Plugin Message
|
||||||
|
registerIncoming(State.PLAY, 0x09, 0x15, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -515,7 +547,7 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Craft recipe request
|
// Craft recipe request
|
||||||
registerIncoming(State.PLAY, 0x12, 0x14, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x12, 0x16, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -528,12 +560,12 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerIncoming(State.PLAY, 0x13, 0x15);
|
registerIncoming(State.PLAY, 0x13, 0x17);
|
||||||
registerIncoming(State.PLAY, 0x14, 0x16);
|
registerIncoming(State.PLAY, 0x14, 0x18);
|
||||||
registerIncoming(State.PLAY, 0x15, 0x17);
|
registerIncoming(State.PLAY, 0x15, 0x19);
|
||||||
registerIncoming(State.PLAY, 0x16, 0x18);
|
registerIncoming(State.PLAY, 0x16, 0x1A);
|
||||||
// Recipe Book Data
|
// Recipe Book Data
|
||||||
registerIncoming(State.PLAY, 0x17, 0x19, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x17, 0x1B, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT); // 0 - Type
|
map(Type.VAR_INT); // 0 - Type
|
||||||
@ -554,9 +586,8 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// New 0x1C - Name Item -> Plugin Message
|
||||||
// New 0x1A - Name Item -> Plugin Message
|
registerIncoming(State.PLAY, 0x09, 0x1C, new PacketRemapper() {
|
||||||
registerIncoming(State.PLAY, 0x09, 0x1A, new PacketRemapper() {
|
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -568,11 +599,11 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerIncoming(State.PLAY, 0x18, 0x1B);
|
registerIncoming(State.PLAY, 0x18, 0x1D);
|
||||||
registerIncoming(State.PLAY, 0x19, 0x1C);
|
registerIncoming(State.PLAY, 0x19, 0x1E);
|
||||||
|
|
||||||
// New 0x1D - Select Trade -> Plugin Message
|
// New 0x1F - Select Trade -> Plugin Message
|
||||||
registerIncoming(State.PLAY, 0x09, 0x1D, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x1F, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -584,8 +615,8 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
map(Type.VAR_INT, Type.INT); // Slot
|
map(Type.VAR_INT, Type.INT); // Slot
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// New 0x1E - Set Beacon Effect -> Plugin Message
|
// New 0x20 - Set Beacon Effect -> Plugin Message
|
||||||
registerIncoming(State.PLAY, 0x09, 0x1E, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x20, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -599,10 +630,10 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerIncoming(State.PLAY, 0x1A, 0x1F);
|
registerIncoming(State.PLAY, 0x1A, 0x21);
|
||||||
|
|
||||||
// New 0x20 - Update Command Block -> Plugin Message
|
// New 0x22 - Update Command Block -> Plugin Message
|
||||||
registerIncoming(State.PLAY, 0x09, 0x20, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x22, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -631,8 +662,8 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// New 0x21 - Update Command Block Minecart -> Plugin Message
|
// New 0x23 - Update Command Block Minecart -> Plugin Message
|
||||||
registerIncoming(State.PLAY, 0x09, 0x21, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x23, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -645,10 +676,10 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// 0x1B -> 0x22 in InventoryPackets
|
// 0x1B -> 0x24 in InventoryPackets
|
||||||
|
|
||||||
// New 0x23 - Update Structure Block -> Message Channel
|
// New 0x25 - Update Structure Block -> Message Channel
|
||||||
registerIncoming(State.PLAY, 0x09, 0x23, new PacketRemapper() {
|
registerIncoming(State.PLAY, 0x09, 0x25, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
create(new ValueCreator() {
|
create(new ValueCreator() {
|
||||||
@ -715,11 +746,11 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registerIncoming(State.PLAY, 0x1C, 0x24);
|
registerIncoming(State.PLAY, 0x1C, 0x26);
|
||||||
registerIncoming(State.PLAY, 0x1D, 0x25);
|
registerIncoming(State.PLAY, 0x1D, 0x27);
|
||||||
registerIncoming(State.PLAY, 0x1E, 0x26);
|
registerIncoming(State.PLAY, 0x1E, 0x28);
|
||||||
registerIncoming(State.PLAY, 0x1F, 0x27);
|
registerIncoming(State.PLAY, 0x1F, 0x29);
|
||||||
registerIncoming(State.PLAY, 0x20, 0x28);
|
registerIncoming(State.PLAY, 0x20, 0x2A);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -120,7 +120,7 @@ public class EntityPackets {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
// Destroy entities
|
// Destroy entities
|
||||||
protocol.registerOutgoing(State.PLAY, 0x32, 0x34, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x32, 0x35, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT_ARRAY); // 0 - Entity IDS
|
map(Type.VAR_INT_ARRAY); // 0 - Entity IDS
|
||||||
@ -136,7 +136,7 @@ public class EntityPackets {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Metadata packet
|
// Metadata packet
|
||||||
protocol.registerOutgoing(State.PLAY, 0x3C, 0x3E, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x3C, 0x3F, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT); // 0 - Entity ID
|
map(Type.VAR_INT); // 0 - Entity ID
|
||||||
|
@ -156,7 +156,7 @@ public class InventoryPackets {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Entity Equipment Packet
|
// Entity Equipment Packet
|
||||||
protocol.registerOutgoing(State.PLAY, 0x3F, 0x41, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x3F, 0x42, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.VAR_INT); // 0 - Entity ID
|
map(Type.VAR_INT); // 0 - Entity ID
|
||||||
@ -201,7 +201,7 @@ public class InventoryPackets {
|
|||||||
);
|
);
|
||||||
|
|
||||||
// Plugin message
|
// Plugin message
|
||||||
protocol.registerIncoming(State.PLAY, 0x09, 0x09, new PacketRemapper() {
|
protocol.registerIncoming(State.PLAY, 0x09, 0x0A, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.STRING); // Channel
|
map(Type.STRING); // Channel
|
||||||
@ -234,7 +234,7 @@ public class InventoryPackets {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Creative Inventory Action
|
// Creative Inventory Action
|
||||||
protocol.registerIncoming(State.PLAY, 0x1B, 0x22, new PacketRemapper() {
|
protocol.registerIncoming(State.PLAY, 0x1B, 0x24, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.SHORT); // 0 - Slot
|
map(Type.SHORT); // 0 - Slot
|
||||||
|
@ -131,7 +131,7 @@ public class WorldPackets {
|
|||||||
protocol.registerOutgoing(State.PLAY, 0x19, 0x1A);
|
protocol.registerOutgoing(State.PLAY, 0x19, 0x1A);
|
||||||
|
|
||||||
// Chunk Data
|
// Chunk Data
|
||||||
protocol.registerOutgoing(State.PLAY, 0x20, 0x21, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x20, 0x22, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@ -194,7 +194,7 @@ public class WorldPackets {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Particle
|
// Particle
|
||||||
protocol.registerOutgoing(State.PLAY, 0x22, 0x23, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x22, 0x24, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
public void registerMap() {
|
public void registerMap() {
|
||||||
map(Type.INT); // 0 - Particle ID
|
map(Type.INT); // 0 - Particle ID
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<name>viaversion-jar</name>
|
<name>viaversion-jar</name>
|
||||||
|
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<name>viaversion-parent</name>
|
<name>viaversion-parent</name>
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>viaversion-parent</artifactId>
|
<artifactId>viaversion-parent</artifactId>
|
||||||
<groupId>us.myles</groupId>
|
<groupId>us.myles</groupId>
|
||||||
<version>1.4.0-1.13-pre6</version>
|
<version>1.4.0-1.13-pre7</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ public class SpongeCommandHandler extends ViaCommandHandler implements CommandCa
|
|||||||
}
|
}
|
||||||
|
|
||||||
public List<String> getSuggestions(CommandSource source, String arguments) throws CommandException {
|
public List<String> getSuggestions(CommandSource source, String arguments) throws CommandException {
|
||||||
String[] args = arguments.split(" "); // ViaCommandHandler handles empty String in array
|
String[] args = arguments.split(" ", -1); // ViaCommandHandler handles empty String in array. -1: do not discard empty strings
|
||||||
return onTabComplete(new SpongeCommandSender(source), args);
|
return onTabComplete(new SpongeCommandSender(source), args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren