#include <DisconnectManager.h>
Public Member Functions | |
| DisconnectManager () | |
| virtual | ~DisconnectManager () |
| void | init () |
| void | update (ConnectionManager *conMgr) |
| void | processDisconnectCommand (NetCommandRef *ref, ConnectionManager *conMgr) |
| void | allCommandsReady (UnsignedInt frame, ConnectionManager *conMgr, Bool waitForPacketRouter=TRUE) |
| void | nextFrame (UnsignedInt frame, ConnectionManager *conMgr) |
| Bool | allowedToContinue () |
| Allow the next frame to go through? | |
| void | playerHasAdvancedAFrame (Int slot, UnsignedInt frame) |
| this player has advanced to that frame. | |
| void | voteForPlayerDisconnect (Int slot, ConnectionManager *conMgr) |
| UnsignedInt | getPingFrame () |
| Int | getPingsSent () |
| Int | getPingsRecieved () |
Protected Attributes | |
| UnsignedInt | m_lastFrame |
| time_t | m_lastFrameTime |
| DisconnectStateType | m_disconnectState |
| UnsignedInt | m_packetRouterFallback [MAX_SLOTS] |
| UnsignedInt | m_currentPacketRouterIndex |
| time_t | m_lastKeepAliveSendTime |
| time_t | m_playerTimeouts [MAX_SLOTS - 1] |
| time_t | m_packetRouterTimeout |
| DisconnectVoteStruct | m_playerVotes [MAX_SLOTS][MAX_SLOTS] |
| UnsignedInt | m_disconnectFrames [MAX_SLOTS] |
| Bool | m_disconnectFramesReceived [MAX_SLOTS] |
| Bool | m_haveNotifiedOtherPlayersOfCurrentFrame |
| time_t | m_timeOfDisconnectScreenOn |
| Int | m_pingsSent |
| Int | m_pingsRecieved |
| UnsignedInt | m_pingFrame |
Definition at line 48 of file DisconnectManager.h.
| DisconnectManager::DisconnectManager | ( | ) |
Definition at line 44 of file DisconnectManager.cpp.
|
virtual |
Definition at line 73 of file DisconnectManager.cpp.
| void DisconnectManager::allCommandsReady | ( | UnsignedInt | frame, |
| ConnectionManager * | conMgr, | ||
| Bool | waitForPacketRouter = TRUE ) |
Definition at line 435 of file DisconnectManager.cpp.
|
protected |
returns true if all players are stuck on the same frame.
Definition at line 645 of file DisconnectManager.cpp.
| Bool DisconnectManager::allowedToContinue | ( | ) |
Allow the next frame to go through?
Definition at line 453 of file DisconnectManager.cpp.
|
protected |
Definition at line 418 of file DisconnectManager.cpp.
return the number of disconnect votes a player has.
Definition at line 776 of file DisconnectManager.cpp.
|
protected |
Definition at line 546 of file DisconnectManager.cpp.
|
protected |
returns the highest frame that people have got to.
Definition at line 740 of file DisconnectManager.cpp.
| UnsignedInt DisconnectManager::getPingFrame | ( | ) |
Definition at line 187 of file DisconnectManager.cpp.
| Int DisconnectManager::getPingsRecieved | ( | ) |
Definition at line 197 of file DisconnectManager.cpp.
| Int DisconnectManager::getPingsSent | ( | ) |
Definition at line 192 of file DisconnectManager.cpp.
returns true if this player has timed out.
Definition at line 691 of file DisconnectManager.cpp.
| void DisconnectManager::init | ( | ) |
Definition at line 76 of file DisconnectManager.cpp.
|
protected |
returns true if the local player is next in line to be the packet router with all the players that have timed out being taken out of the picture.
Definition at line 667 of file DisconnectManager.cpp.
|
protected |
returns true if the player has neither timed out or been voted out.
Definition at line 750 of file DisconnectManager.cpp.
|
protected |
returns true if this player has been voted out.
Definition at line 727 of file DisconnectManager.cpp.
| void DisconnectManager::nextFrame | ( | UnsignedInt | frame, |
| ConnectionManager * | conMgr ) |
Definition at line 429 of file DisconnectManager.cpp.
| void DisconnectManager::playerHasAdvancedAFrame | ( | Int | slot, |
| UnsignedInt | frame ) |
this player has advanced to that frame.
Definition at line 768 of file DisconnectManager.cpp.
|
protected |
Definition at line 476 of file DisconnectManager.cpp.
| void DisconnectManager::processDisconnectCommand | ( | NetCommandRef * | ref, |
| ConnectionManager * | conMgr ) |
Definition at line 270 of file DisconnectManager.cpp.
|
protected |
Definition at line 357 of file DisconnectManager.cpp.
|
protected |
Definition at line 289 of file DisconnectManager.cpp.
|
protected |
Definition at line 297 of file DisconnectManager.cpp.
|
protected |
Definition at line 397 of file DisconnectManager.cpp.
|
protected |
Definition at line 344 of file DisconnectManager.cpp.
|
protected |
< set it to screen on so that the next call to AllCommandsReady can set up everything for the next frame properly.
Definition at line 322 of file DisconnectManager.cpp.
|
protected |
Definition at line 304 of file DisconnectManager.cpp.
|
protected |
Definition at line 636 of file DisconnectManager.cpp.
|
protected |
Definition at line 527 of file DisconnectManager.cpp.
|
protected |
reset the votes for this player.
Definition at line 792 of file DisconnectManager.cpp.
|
protected |
Definition at line 523 of file DisconnectManager.cpp.
|
protected |
Definition at line 513 of file DisconnectManager.cpp.
|
protected |
Definition at line 583 of file DisconnectManager.cpp.
|
protected |
Definition at line 460 of file DisconnectManager.cpp.
|
protected |
send a destruct player network message.
Definition at line 706 of file DisconnectManager.cpp.
|
protected |
Definition at line 608 of file DisconnectManager.cpp.
Definition at line 489 of file DisconnectManager.cpp.
|
protected |
This gets called when the disconnect screen is first turned on.
Definition at line 531 of file DisconnectManager.cpp.
Definition at line 501 of file DisconnectManager.cpp.
| void DisconnectManager::update | ( | ConnectionManager * | conMgr | ) |
Definition at line 102 of file DisconnectManager.cpp.
|
protected |
Definition at line 203 of file DisconnectManager.cpp.
|
protected |
Definition at line 254 of file DisconnectManager.cpp.
| void DisconnectManager::voteForPlayerDisconnect | ( | Int | slot, |
| ConnectionManager * | conMgr ) |
Definition at line 623 of file DisconnectManager.cpp.
|
protected |
Definition at line 111 of file DisconnectManager.h.
|
protected |
Definition at line 121 of file DisconnectManager.h.
|
protected |
Definition at line 122 of file DisconnectManager.h.
|
protected |
Definition at line 108 of file DisconnectManager.h.
|
protected |
Definition at line 123 of file DisconnectManager.h.
|
protected |
Definition at line 106 of file DisconnectManager.h.
|
protected |
Definition at line 107 of file DisconnectManager.h.
|
protected |
Definition at line 113 of file DisconnectManager.h.
|
protected |
Definition at line 110 of file DisconnectManager.h.
|
protected |
Definition at line 116 of file DisconnectManager.h.
|
protected |
Definition at line 128 of file DisconnectManager.h.
|
protected |
Definition at line 127 of file DisconnectManager.h.
|
protected |
Definition at line 126 of file DisconnectManager.h.
|
protected |
Definition at line 115 of file DisconnectManager.h.
|
protected |
Definition at line 118 of file DisconnectManager.h.
|
protected |
Definition at line 125 of file DisconnectManager.h.