Enabling banning a player from the client (as admin).
This commit is contained in:
@@ -99,6 +99,7 @@ public:
|
||||
void SendReportAvatar(unsigned reportedPlayerId, const std::string &avatarHash);
|
||||
void SendReportGameName(unsigned reportedGameId);
|
||||
void SendAdminRemoveGame(unsigned removeGameId);
|
||||
void SendAdminBanPlayer(unsigned playerId);
|
||||
|
||||
void StartAsyncRead();
|
||||
virtual void CloseSession(boost::shared_ptr<SessionData> session);
|
||||
|
||||
@@ -386,6 +386,16 @@ ClientThread::SendAdminRemoveGame(unsigned removeGameId)
|
||||
m_ioService->post(boost::bind(&ClientThread::SendSessionPacket, shared_from_this(), packet));
|
||||
}
|
||||
|
||||
void
|
||||
ClientThread::SendAdminBanPlayer(unsigned playerId)
|
||||
{
|
||||
boost::shared_ptr<NetPacket> packet(new NetPacket);
|
||||
packet->GetMsg()->set_messagetype(PokerTHMessage::Type_AdminBanPlayerMessage);
|
||||
AdminBanPlayerMessage *netBan = packet->GetMsg()->mutable_adminbanplayermessage();
|
||||
netBan->set_banplayerid(playerId);
|
||||
m_ioService->post(boost::bind(&ClientThread::SendSessionPacket, shared_from_this(), packet));
|
||||
}
|
||||
|
||||
void
|
||||
ClientThread::StartAsyncRead()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user