コード例 #1
0
        public static void HandleVoiceRosterUpdate(Packet packet)
        {
            packet.ReadGuid("Group GUID");
            packet.ReadInt16("Channel ID");
            packet.ReadByte("Channel Type"); // 0: channel, 2: party
            packet.ReadCString("Channel Name");
            packet.WriteLine("Encryption Key: " + Utilities.ByteArrayToHexString(packet.ReadBytes(16)));
            packet.WriteLine("IP: " + packet.ReadIPAddress());
            packet.ReadInt16("Voice Server Port");

            var count = packet.ReadByte("Player Count");

            packet.ReadGuid("Leader GUID");

            var leaderFlags1 = packet.ReadByte();
            packet.WriteLine("Leader Flags 1: 0x" + leaderFlags1.ToString("X2"));

            var leaderFlags2 = packet.ReadByte();
            packet.WriteLine("Leader Flags 2: 0x" + leaderFlags2.ToString("X2"));

            for (var i = 0; i < count - 1; i++)
            {
                packet.ReadGuid("Player GUID");
                packet.ReadByte("Index");
                var flags1 = packet.ReadByte();
                packet.WriteLine("Flags 1: 0x" + flags1.ToString("X2"));
                var flags2 = packet.ReadByte();
                packet.WriteLine("Flags 2: 0x" + flags2.ToString("X2"));
            }
        }
コード例 #2
0
        public static void HandleVoiceRosterUpdate(Packet packet)
        {
            packet.ReadGuid("Group GUID");
            packet.ReadInt16("Channel ID");
            packet.ReadByte("Channel Type"); // 0: channel, 2: party
            packet.ReadCString("Channel Name");
            packet.ReadBytes("Encryption Key", 16);
            packet.ReadIPAddress("IP");
            packet.ReadInt16("Voice Server Port");

            var count = packet.ReadByte("Player Count");

            packet.ReadGuid("Leader GUID");

            var leaderFlags1 = packet.ReadByte();
            packet.AddValue("Leader Flags 1", "0x" + leaderFlags1.ToString("X2"));

            var leaderFlags2 = packet.ReadByte();
            packet.AddValue("Leader Flags 2", "0x" + leaderFlags2.ToString("X2"));

            for (var i = 0; i < count - 1; i++)
            {
                packet.ReadGuid("Player GUID");
                packet.ReadByte("Index");
                var flags1 = packet.ReadByte();
                packet.AddValue("Flags 1", "0x" + flags1.ToString("X2"));
                var flags2 = packet.ReadByte();
                packet.AddValue("Flags 2", "0x" + flags2.ToString("X2"));
            }
        }
コード例 #3
0
 public static void HandleRedirectClient(Packet packet)
 {
     var ip = packet.ReadIPAddress();
     packet.WriteLine("IP Address: {0}", ip);
     packet.ReadUInt16("Port");
     packet.ReadInt32("Token");
     var hash = packet.ReadBytes(20);
     packet.WriteLine("Address SHA-1 Hash: {0}", Utilities.ByteArrayToHexString(hash));
 }
コード例 #4
0
 public static void HandleConnectToFailed(Packet packet)
 {
     packet.WriteLine("IP Address: {0}", packet.ReadIPAddress());
     packet.ReadByte("Reason?");
 }
コード例 #5
0
 public static void HandleRedirectClient(Packet packet)
 {
     packet.ReadIPAddress("IP Address");
     packet.ReadUInt16("Port");
     packet.ReadInt32("Token");
     packet.ReadBytes("Address SHA-1 Hash", 20);
 }
コード例 #6
0
        public static void HandleRedirectClient(Packet packet)
        {
            var ip = packet.ReadIPAddress();
            packet.Writer.WriteLine("IP Address: " + ip);

            var port = packet.ReadUInt16();
            packet.Writer.WriteLine("Port: " + port);

            var unk = packet.ReadInt32();
            packet.Writer.WriteLine("Token: " + unk);

            var hash = packet.ReadBytes(20);
            packet.Writer.WriteLine("Address SHA-1 Hash: " + Utilities.ByteArrayToHexString(hash));
        }