(svn r22063) -Change: make the "has network" check also check whether the client is actually fully connected

This commit is contained in:
rubidium
2011-02-11 22:10:10 +00:00
parent e3b44f460f
commit ac28a10197
3 changed files with 13 additions and 1 deletions

View File

@@ -463,6 +463,15 @@ NetworkRecvStatus ClientNetworkGameSocketHandler::SendMove(CompanyID company, co
return NETWORK_RECV_STATUS_OKAY;
}
/**
* Check whether the client is actually connected (and in the game).
* @return True when the client is connected.
*/
bool ClientNetworkGameSocketHandler::IsConnected()
{
return my_client != NULL && my_client->status == STATUS_ACTIVE;
}
/***********
* Receiving functions