Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-27 08:30:09 +01:00
fix book signing and opening in 18w50a
Dieser Commit ist enthalten in:
Ursprung
aa2ff4b741
Commit
7f5073476c
@ -85,6 +85,11 @@ public class InventoryPackets {
|
|||||||
wrapper.passthrough(Type.INT); // Number of tools uses
|
wrapper.passthrough(Type.INT); // Number of tools uses
|
||||||
wrapper.passthrough(Type.INT); // Maximum number of trade uses
|
wrapper.passthrough(Type.INT); // Maximum number of trade uses
|
||||||
}
|
}
|
||||||
|
} else if (channel.equals("minecraft:book_open") || channel.equals("book_open")) {
|
||||||
|
int hand = wrapper.read(Type.VAR_INT);
|
||||||
|
wrapper.clearPacket();
|
||||||
|
wrapper.setId(0x2C);
|
||||||
|
wrapper.write(Type.VAR_INT, hand);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -28,6 +28,19 @@ public class PlayerPackets {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Edit Book
|
||||||
|
protocol.registerIncoming(State.PLAY, 0x0B, 0x0B, new PacketRemapper() {
|
||||||
|
@Override
|
||||||
|
public void registerMap() {
|
||||||
|
handler(new PacketHandler() {
|
||||||
|
@Override
|
||||||
|
public void handle(PacketWrapper wrapper) throws Exception {
|
||||||
|
InventoryPackets.toServer(wrapper.passthrough(Type.FLAT_VAR_INT_ITEM));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
// Player Digging
|
// Player Digging
|
||||||
protocol.registerIncoming(State.PLAY, 0x18, 0x18, new PacketRemapper() {
|
protocol.registerIncoming(State.PLAY, 0x18, 0x18, new PacketRemapper() {
|
||||||
@Override
|
@Override
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren