MCPcopy Create free account
hub / github.com/dhewm/dhewm3 / SendReliableGameMessageExcluding

Method SendReliableGameMessageExcluding

neo/framework/async/AsyncServer.cpp:2271–2291  ·  view source on GitHub ↗

================== idAsyncServer::LocalClientSendReliableMessageExcluding ================== */

Source from the content-addressed store, hash-verified

2269==================
2270*/
2271void idAsyncServer::SendReliableGameMessageExcluding( int clientNum, const idBitMsg &msg ) {
2272 int i;
2273 idBitMsg outMsg;
2274 byte msgBuf[MAX_MESSAGE_SIZE];
2275
2276 assert( clientNum >= 0 && clientNum < MAX_ASYNC_CLIENTS );
2277
2278 outMsg.Init( msgBuf, sizeof( msgBuf ) );
2279 outMsg.WriteByte( SERVER_RELIABLE_MESSAGE_GAME );
2280 outMsg.WriteData( msg.GetData(), msg.GetSize() );
2281
2282 for ( i = 0; i < MAX_ASYNC_CLIENTS; i++ ) {
2283 if ( i == clientNum ) {
2284 continue;
2285 }
2286 if ( clients[i].clientState != SCS_INGAME ) {
2287 continue;
2288 }
2289 SendReliableMessage( i, outMsg );
2290 }
2291}
2292
2293/*
2294==================

Callers 1

Calls 5

InitMethod · 0.45
WriteByteMethod · 0.45
WriteDataMethod · 0.45
GetDataMethod · 0.45
GetSizeMethod · 0.45

Tested by

no test coverage detected