del[protocol]: deprecate protocolId() method

This commit is contained in:
godotg
2023-09-03 15:20:48 +08:00
parent da31160d60
commit 7c1f3ffdc0
11 changed files with 24 additions and 26 deletions
@@ -57,7 +57,7 @@ public class ProtocolManager {
* serialize the packet into the buffer
*/
public static void write(ByteBuf buffer, IPacket packet) {
var protocolId = packet.protocolId();
var protocolId = protocolId(packet.getClass());
// write the protocolId
ByteBufUtils.writeShort(buffer, protocolId);
// write the package