void NewNickServIdentifyDialog::accept ()
	{
		if (GetServer ().isEmpty () ||
				GetNickName ().isEmpty () ||
				GetNickServNickName ().isEmpty () ||
				GetAuthString ().isEmpty () ||
				GetAuthMessage ().isEmpty ())
			return;

		QDialog::accept ();
	}
Exemplo n.º 2
0
void cPlayer::Send_PlayerInfo()
{
	MyPlayerInfoAq* pInfo = (MyPlayerInfoAq*)PrepareSendPacket( sizeof( MyPlayerInfoAq ) );
	if( NULL == pInfo )
		return;
	pInfo->s_sType = MyPlayerInfo_Aq;
	pInfo->s_byDur = GetDur();
	pInfo->s_byLevel = GetLevel();
	pInfo->s_byStr = GetStr();
	pInfo->s_dwExp = GetExp();
	pInfo->s_dwHp = GetHp();
	pInfo->s_dwPKey = GetPKey();
	pInfo->s_dwPos = GetPos();
	strncpy( pInfo->s_szId , GetId() , MAX_ID_LENGTH );
	strncpy( pInfo->s_szName , GetName() , MAX_NAME_LENGTH );
	strncpy( pInfo->s_szNickName , GetNickName() , MAX_NICKNAME_LENGTH );
	SendPost( sizeof( MyPlayerInfoAq ) );
}
Exemplo n.º 3
0
	void IrcServerHandler::IncomingNoticeMessage (const QString& nick, const QString& msg)
	{
		ShowAnswer ("NOTICE", msg);
		QList<NickServIdentify> list = Core::Instance ()
				.GetNickServIdentifyWithMainParams (ServerOptions_.ServerName_,
						GetNickName (),
						nick);

		if (list.isEmpty ())
			return;

		Q_FOREACH (const NickServIdentify& nsi, list)
		{
			QRegExp authRegExp (nsi.AuthString_,
					Qt::CaseInsensitive,
					QRegExp::Wildcard);
			if (authRegExp.indexIn (msg) == -1)
				continue;

			SendMessage2Server (nsi.AuthMessage_.split (' '));
			return;
		}