public static void InviteAccept(ClientInfo _cInfo)
        {
            string _clanName;

            if (!ClanData.Invites.TryGetValue(_cInfo.playerId, out _clanName))
            {
                string _phrase113 = "{PlayerName} you have not been invited to any clans.";
                if (Phrases._Phrases.TryGetValue(113, out _phrase113))
                {
                    _phrase113 = _phrase113.Replace("{PlayerName}", _cInfo.playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase113, CustomCommands._chatcolor), "Server"));
            }
            else if (!ClanData.ClansList.Contains(_clanName))
            {
                string _phrase114 = "{PlayerName} the clan could not be found.";
                if (Phrases._Phrases.TryGetValue(114, out _phrase114))
                {
                    _phrase114 = _phrase114.Replace("{PlayerName}", _cInfo.playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase114, CustomCommands._chatcolor), "Server"));
                ClanData.Invites.Remove(_cInfo.playerId);
                ClanData.UpdateInviteData();
            }
            else
            {
                ClanData.AddMember(_clanName, _cInfo.playerId);
                List <ClientInfo> _cInfoList = ConnectionManager.Instance.GetClients();
                foreach (ClientInfo _cInfop in _cInfoList)
                {
                    if (ClanData.PlayersList.Contains(_cInfop.playerId))
                    {
                        string _clanName1;
                        if (ClanData.Players.TryGetValue(_cInfop.playerId, out _clanName1))
                        {
                            if (_clanName1 == _clanName)
                            {
                                string _phrase115 = "{PlayerName} has joined the clan.";
                                if (Phrases._Phrases.TryGetValue(115, out _phrase115))
                                {
                                    _phrase115 = _phrase115.Replace("{PlayerName}", _cInfo.playerName);
                                }
                                _cInfop.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase115, CustomCommands._chatcolor), "Server"));
                            }
                        }
                    }
                }
            }
        }
 public static void InviteDecline(ClientInfo _cInfo)
 {
     if (!ClanData.InvitesList.Contains(_cInfo.playerId))
     {
         string _phrase113 = "{PlayerName} you have not been invited to any clans.";
         if (Phrases._Phrases.TryGetValue(113, out _phrase113))
         {
             _phrase113 = _phrase113.Replace("{PlayerName}", _cInfo.playerName);
         }
         _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase113, CustomCommands._chatcolor), "Server"));
     }
     else
     {
         ClanData.Invites.Remove(_cInfo.playerId);
         ClanData.UpdateInviteData();
         string _phrase116 = "{PlayerName} you have declined the invite to the clan.";
         if (Phrases._Phrases.TryGetValue(116, out _phrase116))
         {
             _phrase116 = _phrase116.Replace("{PlayerName}", _cInfo.playerName);
         }
         _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase116, CustomCommands._chatcolor), "Server"));
     }
 }
        public static void InviteMember(ClientInfo _cInfo, string _playerName)
        {
            ClientInfo _newMember = ConsoleHelper.ParseParamIdOrName(_playerName);

            if (!ClanData.OfficersList.Contains(_cInfo.playerId))
            {
                string _phrase107 = "{PlayerName} you do not have permissions to use this command.";
                if (Phrases._Phrases.TryGetValue(107, out _phrase107))
                {
                    _phrase107 = _phrase107.Replace("{PlayerName}", _cInfo.playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase107, CustomCommands._chatcolor), "Server"));
            }
            else if (_newMember == null)
            {
                string _phrase108 = "{PlayerName} the name {TargetPlayerName} was not found.";
                if (Phrases._Phrases.TryGetValue(108, out _phrase108))
                {
                    _phrase108 = _phrase108.Replace("{PlayerName}", _cInfo.playerName);
                    _phrase108 = _phrase108.Replace("{TargetPlayerName}", _playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase108, CustomCommands._chatcolor), "Server"));
            }
            else if (ClanData.PlayersList.Contains(_newMember.playerId))
            {
                string _phrase109 = "{PlayerName} is already a member of a clan.";
                if (Phrases._Phrases.TryGetValue(109, out _phrase109))
                {
                    _phrase109 = _phrase109.Replace("{PlayerName}", _playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase109, CustomCommands._chatcolor), "Server"));
            }
            else if (ClanData.InvitesList.Contains(_newMember.playerId))
            {
                string _phrase110 = "{PlayerName} already has pending clan invites.";
                if (Phrases._Phrases.TryGetValue(110, out _phrase110))
                {
                    _phrase110 = _phrase110.Replace("{PlayerName}", _playerName);
                }
                _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase110, CustomCommands._chatcolor), "Server"));
            }
            else
            {
                string _clanName;
                if (ClanData.Officers.TryGetValue(_cInfo.playerId, out _clanName))
                {
                    string _phrase111 = "{PlayerName} you have been invited to join the clan {ClanName}. Type /clanaccept to join or /clandecline to decline the offer.";
                    if (Phrases._Phrases.TryGetValue(111, out _phrase111))
                    {
                        _phrase111 = _phrase111.Replace("{PlayerName}", _newMember.playerName);
                        _phrase111 = _phrase111.Replace("{ClanName}", _clanName);
                    }
                    string _phrase112 = "{PlayerName} you have invited {InvitedPlayerName} to the clan {ClanName}.";
                    if (Phrases._Phrases.TryGetValue(112, out _phrase112))
                    {
                        _phrase112 = _phrase112.Replace("{PlayerName}", _cInfo.playerName);
                        _phrase112 = _phrase112.Replace("{InvitedPlayerName}", _newMember.playerName);
                        _phrase112 = _phrase112.Replace("{ClanName}", _clanName);
                    }
                    ClanData.Invites.Add(_newMember.playerId, _clanName);
                    ClanData.UpdateInviteData();
                    _newMember.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase111, CustomCommands._chatcolor), "Server"));
                    _cInfo.SendPackage(new NetPackageGameMessage(string.Format("{1}{0}[-]", _phrase112, CustomCommands._chatcolor), "Server"));
                }
            }
        }