MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / GetPlayerHostIP

Method GetPlayerHostIP

engine/Poseidon/Network/NetTransportNet.cpp:2531–2547  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2529 enterUsr();
2530 if (to == DPNID_ALL_PLAYERS_GROUP)
2531 { // broadcast to all players
2532#ifdef NET_LOG_SERVER_SEND
2533 NetLog("Peer(%u): NetServer::SendMsg: broadcast to all players", getServerPeer()->getPeerId());
2534#endif
2535 IteratorState it;
2536 if (users.getFirst(it, channel))
2537 {
2538 do
2539 {
2540 msg = NetMessagePool::pool()->newMessage(bufferSize, channel);
2541 if (!msg)
2542 {
2543 leaveUsr();
2544 RptF("NetServer: pool()->newMessage failed when sending to %d", to);
2545 return false;
2546 }
2547 msg->setFlags(MSG_ALL_FLAGS, fl);
2548 if (fl)
2549 {
2550 msg->setOrderedPrevious(); // VIM is set ORDERED automatically

Callers 2

OnMessageMethod · 0.45
BanMethod · 0.45

Calls 3

getDistantAddressMethod · 0.80
RStringClass · 0.50
getMethod · 0.45

Tested by

no test coverage detected