MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / SendGameOver

Function SendGameOver

netcon/mtclient/mtgametrack.cpp:339–363  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

337}
338
339int SendGameOver() {
340 IdleGameTracker();
341
342 if (SendingGameOver == 3) {
343 // Request timed out.
344 return 2;
345 }
346 if (SendingGameOver == 2) {
347 SendingGameOver = 0;
348 return 1;
349 }
350 if (SendingGameOver == 1) {
351 // Wait until it's sent.
352 return 0;
353 }
354 if (SendingGameOver == 0) {
355 LastGameOverPacket = DLLtimer_GetTime();
356 FirstGameOverPacket = DLLtimer_GetTime();
357 SendingGameOver = 1;
358 TrackerGameIsRunning = 0;
359 SendGameTrackerPacker(&GameOverPacket);
360 return 0;
361 }
362 return 0;
363}
364
365void AckPacket(int sig) {
366 TrackAckPacket.sig = sig;

Callers 1

DoMTGameOverFunction · 0.85

Calls 2

IdleGameTrackerFunction · 0.85
SendGameTrackerPackerFunction · 0.85

Tested by

no test coverage detected