MCPcopy Create free account
hub / github.com/Warzone2100/warzone2100 / dumpLocalDebugSyncLogByTime

Function dumpLocalDebugSyncLogByTime

lib/netplay/sync_debug.cpp:709–728  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

707}
708
709static size_t dumpLocalDebugSyncLogByTime(uint32_t time)
710{
711 unsigned logIndex;
712 for (logIndex = 0; logIndex < MAX_SYNC_HISTORY; ++logIndex)
713 {
714 if (syncDebugLog[logIndex].getGameTime() == time)
715 {
716 break; // found the log index for this time
717 }
718 }
719
720 if (logIndex >= MAX_SYNC_HISTORY)
721 {
722 // did not find it
723 debug(LOG_WARNING, "Couldn't find gameTime: %" PRIu32 " in history", time);
724 return 0;
725 }
726
727 return dumpLocalDebugSyncLog(logIndex);
728}
729
730void recvDebugSync(NETQUEUE queue)
731{

Callers 2

recvDebugSyncFunction · 0.85

Calls 2

dumpLocalDebugSyncLogFunction · 0.85
getGameTimeMethod · 0.80

Tested by

no test coverage detected