int CRTMessenger::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << m_dwState; ar << static_cast<int>( size() ); for( map<u_long, Friend>::iterator i = begin(); i != end(); ++i ) { ar << i->first; ar.Write( &i->second, sizeof(Friend) ); } } else { clear(); ar >> m_dwState; int nSize; ar >> nSize; if( nSize > MAX_FRIEND ) return nSize; u_long idFriend; int i; for( i = 0; i < nSize; i++ ) { ar >> idFriend; Friend f; ar.Read( &f, sizeof(Friend) ); SetFriend( idFriend, &f ); } } return 0; }
void CDPAccountClient::OnServersetList( CAr & ar, DPID dpid ) { ar.ReadString( g_dpCertifier.m_szVer ); #ifdef __SECURITY_0628 ar.ReadString( g_dpCertifier.m_szResVer ); #endif // __SECURITY_0628 ar >> g_dpCertifier.m_dwSizeofServerset; LPSERVER_DESC pServer; for( DWORD i = 0; i < g_dpCertifier.m_dwSizeofServerset; i++ ) { pServer = g_dpCertifier.m_aServerset + i; ar >> pServer->dwParent; ar >> pServer->dwID; ar.ReadString( pServer->lpName, 36 ); ar.ReadString( pServer->lpAddr, 16 ); ar >> pServer->b18; ar >> pServer->lCount; ar >> pServer->lEnable; ar >> pServer->lMax; // if( pServer->dwParent != NULL_ID ) { u_long uId = pServer->dwParent * 100 + pServer->dwID; g_dpCertifier.m_2ServersetPtr.insert( map<u_long, LPSERVER_DESC>::value_type( uId, pServer ) ); } } }
void CGlobalGiftbox::OnQuery( CDPMng<CBuffer>* pdp, CAr & ar, DPID dpid ) // recv & check & save { u_long idPlayer; DWORD dwGiftbox, dwItem, dwObjId; int nNum, nQueryGiftbox; ar >> idPlayer >> dwGiftbox >> dwItem >> nNum >> dwObjId >> nQueryGiftbox; map<DWORD, int>::iterator i = m_map.find( MAKELONG( (WORD)dwGiftbox, (WORD)dwItem ) ); if( i == m_map.end() ) { Error( "CGlobalGiftbox::OnQuery: key not found, g: %d, i: %d", dwGiftbox, dwItem ); return; } BOOL bResult = FALSE; if( i->second > 0 ) { i->second--; bResult = TRUE; } CAr arResult; arResult << PACKETTYPE_QUERYGLOBALGIFTBOX; arResult << idPlayer << dwGiftbox << dwItem << nNum << dwObjId << nQueryGiftbox << bResult; int nBufSize; LPBYTE lpBuf = arResult.GetBuffer( &nBufSize ); pdp->Send( lpBuf, nBufSize, dpid ); Save(); }
void CServerDesc::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << m_uKey; ar << (short)m_lspJurisdiction.size(); for( list<CJurisdiction*>::iterator i = m_lspJurisdiction.begin(); i != m_lspJurisdiction.end(); ++i ) { ar << (*i)->m_dwWorldID; ar << (*i)->m_rect; ar << (*i)->m_wLeft; ar << (*i)->m_wRight; } ar.WriteString( m_szAddr ); } else { u_long uKey; ar >> uKey; SetKey( uKey ); short nSize; ar >> nSize; for( int i =0; i < nSize; i++ ) { CJurisdiction* pJurisdiction = new CJurisdiction; ar >> pJurisdiction->m_dwWorldID; ar >> pJurisdiction->m_rect; ar >> pJurisdiction->m_wLeft; ar >> pJurisdiction->m_wRight; m_lspJurisdiction.push_back( pJurisdiction ); } ar.ReadString( m_szAddr ); } }
// 과금정보의 ACK void CDPBilling::OnGameStartReceive( CAr & ar, DPID dpid ) { char szAccount[MAX_ID_LENGTH]; char szTimeOverDays[13]; long lRemainDays; long lResult; ar >> lResult; ar.Read( szAccount, MAX_ID_LENGTH ); ar >> lRemainDays; ar.Read( szTimeOverDays, 12 ); szTimeOverDays[12] = '\0'; lResult = ntohl( lResult ); // 호스트 바이 오더로 변환한다. lRemainDays = ntohl( lRemainDays ); // @flyff.jp가 붙은 유저 문자열에서 @flyff.jp를 제거한다 int i; for( i=0; i<MAX_ID_LENGTH; ++i ) { if( szAccount[i] == 0x20 ) break; } i -= ENDMARK_LENGTH; // ENDMARK_LENGTH = strlen("@flyff.jp"); szAccount[i] = '\0'; char szBuffer[1024]; sprintf(szBuffer, "recv 0x00010001 - GAME_START_RECEIVE\nstatus:%d user:%s remainday:%d enddate:%s\n", lResult, szAccount, lRemainDays, szTimeOverDays ); OutputDebugString( szBuffer ); CTime tmOverDays = 0; if( lResult == SUCCESS ) { char sYear[3] = { 0, }; char sMonth[3] = { 0, }; char sDay[3] = { 0, }; char sHour[3] = { 0, }; char sMin[3] = { 0, }; strncpy( sYear, szTimeOverDays, 2 ); strncpy( sMonth, szTimeOverDays + 2, 2 ); strncpy( sDay, szTimeOverDays + 4, 2 ); strncpy( sHour, szTimeOverDays + 6, 2 ); strncpy( sMin, szTimeOverDays + 8, 2 ); tmOverDays = CTime( 2000 + atoi( sYear ), atoi( sMonth ), atoi( sDay ), 0, 0, 0 ); } BILLING_INFO info; info.szAccount = szAccount; info.dwKey = 0; info.lResult = lResult; info.pTimeOverDays = &tmOverDays; // tmOverDays는 lResult가 SUCCESS인 경우에만 설정되면 된다. g_AccountMng.SendBillingResult( &info ); }
void CParty::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << m_uPartyId << m_nKindTroup << m_nSizeofMember; ar << m_nLevel << m_nExp << m_nPoint; ar << m_nTroupsShareExp << m_nTroupeShareItem; ar << m_idDuelParty; for( int i = 0 ; i < MAX_PARTYMODE ; i++ ) { ar << m_nModeTime[i]; } if( m_nKindTroup ) ar.WriteString( m_sParty ); for( i = 0 ; i < m_nSizeofMember ; i++ ) { ar << m_aMember[i].m_uPlayerId; #if __VER < 11 // __SYS_PLAYER_DATA ar << m_aMember[i].m_nLevel; ar << m_aMember[i].m_nJob; #endif // __SYS_PLAYER_DATA ar << m_aMember[i].m_bRemove; #if __VER < 11 // __SYS_PLAYER_DATA ar << m_aMember[i].m_nSex; ar.WriteString( m_aMember[i].m_szName ); #endif // __SYS_PLAYER_DATA } } else { ar >> m_uPartyId >> m_nKindTroup >> m_nSizeofMember; ar >> m_nLevel >> m_nExp >> m_nPoint; ar >> m_nTroupsShareExp >> m_nTroupeShareItem; ar >> m_idDuelParty; for( int i = 0 ; i < MAX_PARTYMODE ; i++ ) { ar >> m_nModeTime[i]; } if( m_nKindTroup ) ar.ReadString( m_sParty, 33 ); for( i = 0 ; i < m_nSizeofMember ; i++ ) { ar >> m_aMember[i].m_uPlayerId; #if __VER < 11 // __SYS_PLAYER_DATA ar >> m_aMember[i].m_nLevel; ar >> m_aMember[i].m_nJob; #endif // __SYS_PLAYER_DATA ar >> m_aMember[i].m_bRemove; #if __VER < 11 // __SYS_PLAYER_DATA ar >> m_aMember[i].m_nSex; ar.ReadString( m_aMember[i].m_szName, 20 ); #endif // __SYS_PLAYER_DATA } } }
void CWantedListSnapshot::Write( CAr& ar ) { ar << m_lRecvTime; ar << (int)m_wantedList.size(); WANTED_ENTRY_VECTOR::iterator it; for( it = m_wantedList.begin(); it != m_wantedList.end(); ++it ) { ar.WriteString( (*it).szPlayer ); ar << (*it).nGold; ar << (*it).nEnd; ar.WriteString( (*it).szMsg ); } }
void CItemBase::Serialize( CAr & ar ) // 11 // 20 { if( ar.IsStoring() ) { ar << m_dwObjId << m_dwItemId; ar << m_liSerialNumber; ar.WriteString( m_szItemText ); } else { ar >> m_dwObjId >> m_dwItemId; ar >> m_liSerialNumber; ar.ReadString( m_szItemText, 32 ); } }
// 빌링서버에 connect될 때, 이를 빌링서버에 알린다. void CDPBilling::SendGSCSStart() { OutputDebugString("send 0x00000005 - GSCS_START\n"); char cbServerName[MAX_SERVERNAME]; AppendEndMark( cbServerName, g_szServerName, MAX_SERVERNAME ); CAr ar; int nBufSize; ar << htonl( static_cast<DWORD>(GSCS_START_SEND) ); ar.Write( cbServerName, MAX_SERVERNAME ); SEND( ar, this, DPID_SERVERPLAYER ); }
void CCampusMember::Serialize( CAr & ar ) { if( ar.IsStoring() ) ar << m_idPlayer << m_nMemberLv; else ar >> m_idPlayer >> m_nMemberLv; }
void CCampusMng::Serialize( CAr & ar ) { int i = 0; if( ar.IsStoring() ) { ar << m_idCampus << m_mapCampus.size(); for( MAP_CAMPUS::iterator it = m_mapCampus.begin(); it != m_mapCampus.end(); ++it ) ( it->second )->Serialize( ar ); ar << m_mapPid2Cid.size(); for( MAP_PID2CID::iterator it2 = m_mapPid2Cid.begin(); it2 != m_mapPid2Cid.end(); ++it2 ) ar << it2->first << it2->second; } else { Clear(); size_t nSize; ar >> m_idCampus >> nSize; for( i = 0; i < (int)( nSize ); ++i ) { CCampus* pCampus = new CCampus; pCampus->Serialize( ar ); m_mapCampus.insert( MAP_CAMPUS::value_type( pCampus->GetCampusId(), pCampus ) ); } ar >> nSize; for( i = 0; i < (int)( nSize ); ++i ) { u_long idPlayer, idCampus; ar >> idPlayer >> idCampus; AddPlayerId2CampusId( idPlayer, idCampus ); } } }
void IBuff::SerializeLevel( CAr & ar ) { if( ar.IsStoring() ) { #ifdef __DBSERVER if( GetType() == BUFF_ITEM2 ) { time_t t = static_cast<time_t>( GetLevel() ) - time_null(); ar << t; } else { ar << m_dwLevel; } #else // __DBSERVER ar << m_dwLevel; #endif // __DBSERVER } else { #ifdef __DBSERVER if( GetType() == BUFF_ITEM2 ) { time_t t; ar >> t; SetLevel( time_null() + t ); } else {
void CGuildWarMng::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << m_id; ar << GetSize(); for( map<u_long, CGuildWar*>::iterator i = m_mapPWar.begin(); i != m_mapPWar.end(); ++i ) ( i->second )->Serialize( ar ); } else { #ifdef __CLIENT Clear(); #endif // __CLIENT ar >> m_id; int nSize; ar >> nSize; for( int i = 0; i < nSize; i++ ) { CGuildWar* pWar = new CGuildWar; pWar->Serialize( ar ); m_mapPWar.insert( map<u_long, CGuildWar*>::value_type( pWar->m_idWar, pWar ) ); } } }
void CPocket::Serialize( CAr & ar ) { CItemContainer<CItemElem>::Serialize( ar ); if( ar.IsStoring() ) { ar << m_bExpired << m_tExpirationDate; if( m_tExpirationDate ) { time_t t = m_tExpirationDate - time_null(); ar << t; } } else { ar >> m_bExpired >> m_tExpirationDate; if( m_tExpirationDate ) { time_t t; ar >> t; #ifdef __CLIENT m_tExpirationDate = time_null() + t; #endif // __CLIENT } } }
void CDPConsole::OnOverview( CAr & ar ) { CTime tm = CTime::GetCurrentTime(); printf( "\n%s", tm.Format( "%Y/%m/%d %H:%M:%S" ) ); printf( "\n--------------------------------------------------------------------------------" ); *sOverview = '\0'; ar.ReadString( sOverview ); #ifdef __QLORD HideAddr( sOverview ); #endif // __QLORD printf( "%s", sOverview ); printf( "--------------------------------------------------------------------------------" ); #ifdef __QLORD printf( "\nCommand: q>" ); #else // __QLORD printf( "\nCommand: r, s, q>" ); #endif // __QLORD if( strstr( sOverview, "x" ) != NULL ) sndPlaySound( "type.wav", SND_ASYNC | SND_LOOP ); else sndPlaySound( NULL, SND_ASYNC ); SetEvent( hPrompt ); }
void CPocketController::Serialize( CAr & ar ) { if( ar.IsStoring() ) { for( int i = 0; i < MAX_POCKET; i++ ) { if( IsAvailable( i, FALSE ) ) { ar << (BYTE)1; m_apPocket[i]->Serialize( ar ); } else ar << (BYTE)0; } } else { Clear(); for( int i = 0; i < MAX_POCKET; i++ ) { BYTE bExists; ar >> bExists; if( !bExists ) continue; Avail( i ); m_apPocket[i]->Serialize( ar ); } } }
// 과금정보 REQ void CDPBilling::SendGameStart( LPCTSTR lpszUserID, LPCTSTR lpszUserIP ) { OutputDebugString("send 0x00000001 - GAME_START\n"); char cbUserID[MAX_ID_LENGTH]; char cbUserIP[MAX_IP_LENGTH]; AppendEndMark( cbUserID, lpszUserID, MAX_ID_LENGTH ); char* p = StrCpyExcludeNull( cbUserIP, lpszUserIP ); AppendSpace( p, cbUserIP + MAX_IP_LENGTH ); CAr ar; int nBufSize; ar << htonl( static_cast<DWORD>(GAME_START_SEND) ); ar.Write( cbUserID, MAX_ID_LENGTH ); ar.Write( cbUserIP, MAX_IP_LENGTH ); SEND( ar, this, DPID_SERVERPLAYER ); }
void CDPLoginSrvr::OnPreJoin( CAr & ar ) { static \ TCHAR lpszAccount[MAX_ACCOUNT], lpszPlayer[MAX_PLAYER]; u_long idPlayer; DWORD dwAuthKey; ar >> dwAuthKey; ar.ReadString( lpszAccount, MAX_ACCOUNT ); ar >> idPlayer; ar.ReadString( lpszPlayer, MAX_PLAYER ); CMclAutoLock Lock( g_PlayerMng.m_AddRemoveLock ); BOOL f = g_PlayerMng.AddPlayer( idPlayer, lpszPlayer, lpszAccount ); // lock if( f == FALSE ) { WriteLog( "OnPreJoin(): AddPlayer() return false, %d, %s", idPlayer, lpszPlayer ); CPlayer* pPlayer = g_PlayerMng.GetPlayer( idPlayer ); // if( !pPlayer ) // { // WriteLog( "OnPreJoin(): ID not found" ); // pPlayer = g_PlayerMng.GetPlayer( lpszPlayer ); // } if( pPlayer ) { if( *pPlayer->lpszAccount != '\0' ) SendQueryRemovePlayer( pPlayer->lpszAccount ); else WriteLog( "OnPreJoin(): lpszAccount == '\0'" ); g_PlayerMng.RemovePlayer( pPlayer ); } else WriteLog( "OnPreJoin(): Player not found" ); } BEFORESEND( ar1, PACKETTYPE_PRE_JOIN ); // result ar1 << dwAuthKey; ar1.WriteString( lpszAccount ); ar1 << idPlayer; ar1.WriteString( lpszPlayer ); ar1 << (BYTE)f; // o SEND( ar1, this, DPID_ALLPLAYERS ); }
void CWantedListSnapshot::Read( CAr& ar ) { m_wantedList.clear(); int nCount; // 리스트의 갯수 ar >> m_lRecvTime; ar >> nCount; for( int i=0; i<nCount; i++) { WANTED_ENTRY entry; ar.ReadString( entry.szPlayer, 64 ); ar >> entry.nGold; ar >> entry.nEnd; ar.ReadString( entry.szMsg, WANTED_MSG_MAX + 1 ); m_wantedList.push_back( entry ); } }
void CWndNeuz::SerializeRegInfo( CAr& ar, DWORD& dwVersion ) { if( ar.IsLoading() ) { } else { dwVersion = 0; } }
void CPiercing::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << GetPiercingSize(); int i; for( i = 0; i < GetPiercingSize(); i++ ) ar << GetPiercingItem( i ); #if __VER >= 12 // __EXT_PIERCING ar << GetUltimatePiercingSize(); for( i = 0; i < GetUltimatePiercingSize(); i++ ) ar << GetUltimatePiercingItem( i ); #endif // __EXT_PIERCING #if __VER >= 15 // __PETVIS ar << m_vtmPetVis.size(); for( int i=0; i<(int)( m_vtmPetVis.size() ); i++ ) ar << GetVisKeepTime( i ) - time_null(); #endif // __PETVIS } else { m_vPiercing.clear(); size_t nSize; ar >> nSize; SetPiercingSize( nSize ); size_t i; for( i = 0; i < nSize; i++ ) { DWORD dwItem; ar >> dwItem; SetPiercingItem( i, dwItem ); } #if __VER >= 12 // __EXT_PIERCING m_vUltimatePiercing.clear(); ar >> nSize; SetUltimatePiercingSize( nSize ); for( i = 0; i < nSize; i++ ) { DWORD dwItem; ar >> dwItem; SetUltimatePiercingItem( i, dwItem ); } #endif // __EXT_PIERCING #if __VER >= 15 // __PETVIS ar >> nSize; SetVisKeepTimeSize( nSize ); for( i=0; i<nSize; i++ ) { time_t tmTemp; ar >> tmTemp; SetVisKeepTime( i, tmTemp + time_null() ); } #endif // __PETVIS } }
void CGuildWar::Serialize( CAr & ar ) { if( ar.IsStoring() ) { ar << m_idWar; ar.Write( &m_Decl, sizeof(m_Decl) ); ar.Write( &m_Acpt, sizeof(m_Acpt) ); ar << m_nFlag; ar << (time_t)m_time.GetTime(); } else { ar >> m_idWar; ar.Read( &m_Decl, sizeof(m_Decl) ); ar.Read( &m_Acpt, sizeof(m_Acpt) ); ar >> m_nFlag; time_t time; ar >> time; m_time = CTime( time ); } }
void CDPCoreClient::OnPreJoin( CAr & ar ) { CHAR lpszAccount[MAX_ACCOUNT], lpszPlayer[MAX_PLAYER]; DWORD dwAuthKey; u_long idPlayer; BYTE f; ar >> dwAuthKey; ar.ReadString( lpszAccount, MAX_ACCOUNT ); ar >> idPlayer; ar.ReadString( lpszPlayer, MAX_PLAYER ); ar >> f; CMclAutoLock Lock( g_UserMng.m_AddRemoveLock ); CUser* pUser = g_UserMng.GetUser( lpszAccount ); if( pUser ) { if( pUser->m_dwAuthKey == dwAuthKey ) { if( f ) // o g_dpLoginSrvr.SendHdr( PACKETTYPE_PRE_JOIN, pUser->m_dpid ); else { WriteLog( "OnPreJoin(): recv 0 from CORE, %s", lpszAccount ); pUser->m_idPlayer = 0; g_dpLoginSrvr.DestroyPlayer( pUser->m_dpid ); } } else { WriteLog( "OnPreJoin(): Different dwAuthKey" ); g_dpLoginSrvr.DestroyPlayer( pUser->m_dpid ); } } else { WriteLog( "OnPreJoin(): Account not found, %s", lpszAccount ); // } }
void CPartyMng::Serialize( CAr & ar ) { #ifndef __WORLDSERVER m_AddRemoveLock.Enter( theLineFile ); // lock1 #endif // __WORLDSERVER if( ar.IsStoring() ) { ar << m_id; int nCount = 0; u_long uOffset = ar.GetOffset(); ar << nCount; for( C2PartyPtr::iterator i = m_2PartyPtr.begin(); i != m_2PartyPtr.end(); ++i ) { CParty* pParty = (CParty*)i->second; pParty->Serialize( ar ); nCount++; } int nBufSize1; LPBYTE lpBuf1 = ar.GetBuffer( &nBufSize1 ); *(UNALIGNED int*)( lpBuf1 + uOffset ) = nCount; } else { int nCount; ar >> m_id; ar >> nCount; for( int i = 0 ; i < nCount ; i++ ) { CParty* pParty = new CParty; // pParty->Lock(); pParty->Serialize( ar ); m_2PartyPtr.insert( C2PartyPtr::value_type( pParty->m_uPartyId, pParty ) ); // pParty->Unlock(); } } #ifndef __WORLDSERVER m_AddRemoveLock.Leave( theLineFile ); // unlock1 #endif // __WORLDSERVER }
void CCtrl::Serialize( CAr & ar ) // 33 { CObj::Serialize( ar ); if( ar.IsStoring() ) { ar << m_objid; } else { ar >> m_objid; } }
// Handlers void CDPCertified::OnSrvrList( CAr & ar, DPID ) { g_bRecvSvrList = TRUE; ar >> g_Neuz.m_dwAuthKey; ar >> g_Neuz.m_cbAccountFlag; long lTimeSpan = 0; #ifdef __BILLING0712 // 결재가 1일 미만 남은경우, 유저가 로그인 할때 몇시간 몇분 남았습니다 라는 메세지를 보여주는 것 ar >> lTimeSpan; #endif // __BILLING0712 #ifdef __GPAUTH_01 if( g_Neuz.m_bGPotatoAuth ) { ar.ReadString( g_Neuz.m_szGPotatoNo, 10 ); #ifdef __GPAUTH_02 ar.ReadString( g_Neuz.m_szCheck, 255 ); #endif // __GPAUTH_02 } #ifdef __EUROPE_0514 char szBak[MAX_ACCOUNT] = { 0,}; ar.ReadString( szBak, MAX_ACCOUNT ); if( lstrcmp( g_Neuz.m_szAccount, szBak ) ) { Error( "CDPCertified.OnSrvrList" ); exit( 0 ); } #endif // __EUROPE_0514 #endif // __GPAUTH_01 if( ::GetLanguage() == LANG_THA ) { long lTimeLeft; ar >> lTimeLeft; // 태국의 경우 돌아오는 22:00시까지의 남은 시간을 받는다. g_Neuz.SetLeftTime( lTimeLeft ); }
void CArena::Serialize( CAr & ar ) { ar << m_Online.size(); for( map<u_long, nomember>::iterator itor = m_Online.begin(); itor != m_Online.end(); ++itor ) { map<u_long, ARENAPLAYER>::iterator it = m_mArenaMap.find( itor->first ); if( it != m_mArenaMap.end() ) { ar << it->second.nKill; ar << it->second.nDeath; ar << it->second.nRow; ar << it->second.nJob; ar << it->second.nDeathMatchWin; ar << it->second.nDeathMatchLose; ar << it->second.nDuelWin; ar << it->second.nDuelLose; ar << (unsigned long)it->second.n64ArenaPoint; ar.WriteString( LPCTSTR( it->second.szName ) ); } else //map.size() == ar >> size ( --> nomatch = crash ). { ar << 0; ar << 0; ar << 0; ar << 0; ar << 0; ar << 0; ar << 0; ar << 0; ar << 0; ar.WriteString( "Deleted" ); } } }
/*------------------------------------------------------------------------------------------------------------------------------------------------------------*/ void CItem::Serialize( CAr & ar ) // 45 { CCtrl::Serialize( ar ); // 33 if( ar.IsStoring() ) { } else { SAFE_DELETE( m_pItemBase ); m_pItemBase = new CItemElem; } m_pItemBase->Serialize( ar ); // 11 }
void CDPLoginSrvr::OnCloseError( CAr & ar, DPID dpid, LPBYTE lpBuf, u_long uBufSize ) { char lpszAccount[MAX_ACCOUNT] = { 0, }; ar.ReadString( lpszAccount, MAX_ACCOUNT ); #ifdef __SECURITY_FIXES if(!prj.IsAllowedLetter(lpszAccount,FALSE)) { return; } #endif // __SECURITY_FIXES g_dpAccountClient.SendRemoveAccount( lpszAccount ); #ifdef __INTERNALSERVER time_t cur = time(NULL); WriteLog( "CDPLoginSrvr::OnCloseError(%s) - %s\n", lpszAccount, ctime( &cur )); #endif }
void CDPCoreClient::OnQueryRemovePlayer( CAr & ar ) { char lpszAccount[MAX_ACCOUNT] = { 0, }; ar.ReadString( lpszAccount, MAX_ACCOUNT ); CMclAutoLock Lock( g_UserMng.m_AddRemoveLock ); CUser* pUser = g_UserMng.GetUser( lpszAccount ); if( pUser ) { pUser->m_idPlayer = 0; g_dpLoginSrvr.DestroyPlayer( pUser->m_dpid ); } else { WriteLog( "OnQueryRemovePlayer(): lpszAccount not found, %s", lpszAccount ); } }