37 : mResult(nResult), mPlayer(player), mChatroom(chatroom) {
46 void *
operator new(
size_t nSize) {
47 return PoolMemAlloc(
static_cast<int>(nSize),
"FindPlayerMsg", 0);
55 void operator delete(
void *pBlock) {
83 return "FindPlayerMsg";
void PrintExtra(PrnStream &stream) const override
Write the error, or the player and the chatroom.
const NetChatroomInfo & GetChatroom() const
Definition findplayermsg.h:97
const char * GetName() const override
Report this message's class name.
Definition findplayermsg.h:82
const LobbyPlayer & GetPlayer() const
Definition findplayermsg.h:102
FindPlayerMsg(int nResult, const LobbyPlayer &player, const NetChatroomInfo &chatroom)
Construct a result.
Definition findplayermsg.h:36
FindPlayerMsg(int nResult)
Construct a failure, with a default player and a chatroom whose identifier is -1.
Definition findplayermsg.h:24
Message * Clone() override
Produce a heap copy of this message.
Definition findplayermsg.h:64
int GetResult() const
Definition findplayermsg.h:107
int Type() override
Report this message's registered identity.
Definition findplayermsg.h:73
A player of the lobby server, as FindPlayerMsg reports it.
Definition lobbyplayer.h:16
Base of every event the game passes between a MsgSource and a MsgSink.
Definition message.h:40
Text output stream.
Definition prnstream.h:16
int g_nFindPlayerMsgType
Identity that FindPlayerMsg::Type() reports.
void * PoolMemAlloc(int nSize, const char *pszTag, int nAlign)
Allocate a block from the pool heaps and bill it to a tag.
void PoolMemFree(void *pBlock)
Return a block PoolMemAlloc() handed out to the pool heap that owns it.
The description of one chat room of the online lobby.
Definition netchatroominfo.h:11