// *************************************************************** // Function: LSPlayerAction.cpp // *************************************************************** #include "Main.h" #include "../../src/SharedStructures.h" //************************************ // Name: IcProcessLsPlayerAction // // Process a player action command from the login server. // // Parameters: // pData - Network message // s - Outgoing network message // pDest - Packet buffer // // Return: // //************************************ void IcProcessLsPlayerAction(NetMessage* pData, NetMessage* s, unsigned char* pDest) { STRUCT_LS_PLAYER_ACTION ls; Read_Struct(pDest+2, &ls, sizeof(STRUCT_LS_PLAYER_ACTION)); PLAYER_DATA* pLir=NULL; //Find the local data for this accountID hash_map::iterator itr; for (itr=GameServInfo.begin(); itr!=GameServInfo.end(); itr++) { if (itr->second.accountId==ls.accountId) { pLir=&itr->second; break; } } //If this account is not on this game server do nothing if (pLir==NULL) { return; } //Check the actions against our list of possible actions switch(ls.action) { case LS_PLAYER_ACTION_KICK: gpGameServer->Kick(pLir->networkId); break; } }