(svn r26449) -Add: Allow more sound sleep for dedicated servers when there's nothing to do and nobody paying attention

This commit is contained in:
planetmaker
2014-04-08 20:19:41 +00:00
parent 8395c08738
commit 1d8c673587
3 changed files with 23 additions and 1 deletions

View File

@@ -96,6 +96,18 @@ byte _network_clients_connected = 0;
/* Some externs / forwards */
extern void StateGameLoop();
/**
* Return whether there is any client connected or trying to connect at all.
* @return whether we have any client activity
*/
bool HasClients()
{
NetworkClientSocket *cs;
FOR_ALL_CLIENT_SOCKETS(cs) return true;
return false;
}
/**
* Basically a client is leaving us right now.
*/