Example #1
0
        /// <summary>Handles a request of kicking a channel member</summary>
        /// <param name="client">the client the incoming packet belongs to</param>
        /// <param name="packet">the full packet</param>
        public static void HandleKickRequest(IRealmClient client, RealmPacketIn packet)
        {
            string        channelName = packet.ReadCString();
            string        targetName  = packet.ReadCString();
            ChannelMember member;
            ChatChannel   chatChannel =
                ChatChannel.EnsurePresence(client.ActiveCharacter, channelName, out member);

            if (chatChannel == null)
            {
                return;
            }
            chatChannel.Kick(member, targetName);
        }