예제 #1
0
        public uint GetPacketID(string packetName)
        {
            PacketOpcodeEntry entry = _opcodeList.Server.Packets.Find(poe => poe.Name == packetName);

            if (entry == null)
            {
                return(0);
            }
            return(entry.ID);
        }
예제 #2
0
        public string GetPacketName(byte opcode, uint id)
        {
            PacketOpcodeEntry entry = _opcodeList.Client.Packets.Find(poe => poe.ID == id && poe.Opcode == opcode);

            if (entry == null)
            {
                return("");
            }
            return(entry.Name);
        }
예제 #3
0
        public byte GetOpcode(string packetName)
        {
            PacketOpcodeEntry entry = _opcodeList.Server.Packets.Find(poe => poe.Name == packetName);

            if (entry == null)
            {
                return(0);
            }
            return(entry.Opcode);
        }