mirror of
https://github.com/ViaVersion/ViaBackwards.git
synced 2024-12-19 16:28:13 +01:00
Fix acknowledge player digging
This commit is contained in:
parent
653a38fbba
commit
a25b002fa8
@ -215,7 +215,6 @@ public class Protocol1_14_4To1_15 extends BackwardsProtocol {
|
|||||||
registerOutgoing(State.PLAY, 0x56, 0x55);
|
registerOutgoing(State.PLAY, 0x56, 0x55);
|
||||||
registerOutgoing(State.PLAY, 0x57, 0x56);
|
registerOutgoing(State.PLAY, 0x57, 0x56);
|
||||||
registerOutgoing(State.PLAY, 0x5A, 0x59);
|
registerOutgoing(State.PLAY, 0x5A, 0x59);
|
||||||
registerOutgoing(State.PLAY, 0x08, 0x5C);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int getNewBlockStateId(int id) {
|
public static int getNewBlockStateId(int id) {
|
||||||
|
@ -106,6 +106,21 @@ public class BlockItemPackets1_15 extends BlockItemRewriter<Protocol1_14_4To1_15
|
|||||||
// Creative Inventory Action
|
// Creative Inventory Action
|
||||||
itemRewriter.registerCreativeInvAction(Type.FLAT_VAR_INT_ITEM, 0x26, 0x26);
|
itemRewriter.registerCreativeInvAction(Type.FLAT_VAR_INT_ITEM, 0x26, 0x26);
|
||||||
|
|
||||||
|
// Acknowledge player digging
|
||||||
|
protocol.registerOutgoing(State.PLAY, 0x08, 0x5C, new PacketRemapper() {
|
||||||
|
@Override
|
||||||
|
public void registerMap() {
|
||||||
|
map(Type.POSITION1_14);
|
||||||
|
map(Type.VAR_INT);
|
||||||
|
handler(new PacketHandler() {
|
||||||
|
@Override
|
||||||
|
public void handle(PacketWrapper wrapper) throws Exception {
|
||||||
|
wrapper.set(Type.VAR_INT, 0, Protocol1_14_4To1_15.getNewBlockStateId(wrapper.get(Type.VAR_INT, 0)));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
// Block Action
|
// Block Action
|
||||||
protocol.registerOutgoing(State.PLAY, 0x0B, 0x0A, new PacketRemapper() {
|
protocol.registerOutgoing(State.PLAY, 0x0B, 0x0A, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user