MCPcopy Create free account
hub / github.com/OpenDungeons/OpenDungeons / stopServer

Method stopServer

source/network/ODServer.cpp:1904–1921  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1902}
1903
1904void ODServer::stopServer()
1905{
1906 // We start by stopping server to make sure no new message comes
1907 ODSocketServer::stopServer();
1908
1909 mServerState = ServerState::StateNone;
1910 mSeatsConfigured = false;
1911 mDisconnectedPlayers.clear();
1912 mPlayerConfig = nullptr;
1913
1914 // Now that the server is stopped, we can remove all pending messages
1915 while(!mServerNotificationQueue.empty())
1916 {
1917 delete mServerNotificationQueue.front();
1918 mServerNotificationQueue.pop_front();
1919 }
1920 mGameMap->clearAll();
1921}
1922
1923void ODServer::notifyExit()
1924{

Callers 4

startServerMethod · 0.45
startClientMethod · 0.45
~GameEditorModeBaseMethod · 0.45
goBackMethod · 0.45

Calls 2

clearMethod · 0.80
clearAllMethod · 0.80

Tested by

no test coverage detected