|
@@ -191,14 +191,14 @@ NetworkRecvStatus ClientNetworkGameSocke
|
|
|
/**
|
|
|
* Handle an error coming from the client side.
|
|
|
* @param res The "error" that happened.
|
|
|
*/
|
|
|
void ClientNetworkGameSocketHandler::ClientError(NetworkRecvStatus res)
|
|
|
{
|
|
|
/* First, send a CLIENT_ERROR to the server, so he knows we are
|
|
|
* disconnection (and why!) */
|
|
|
/* First, send a CLIENT_ERROR to the server, so it knows we are
|
|
|
* disconnected (and why!) */
|
|
|
NetworkErrorCode errorno;
|
|
|
|
|
|
/* We just want to close the connection.. */
|
|
|
if (res == NETWORK_RECV_STATUS_CLOSE_QUERY) {
|
|
|
this->NetworkSocketHandler::CloseConnection();
|
|
|
this->CloseConnection(res);
|
|
@@ -290,13 +290,13 @@ void ClientNetworkGameSocketHandler::Cli
|
|
|
my_client->ClientError(NETWORK_RECV_STATUS_DESYNC);
|
|
|
return false;
|
|
|
}
|
|
|
|
|
|
/* If this is the first time we have a sync-frame, we
|
|
|
* need to let the server know that we are ready and at the same
|
|
|
* frame as he is.. so we can start playing! */
|
|
|
* frame as it is.. so we can start playing! */
|
|
|
if (_network_first_time) {
|
|
|
_network_first_time = false;
|
|
|
SendAck();
|
|
|
}
|
|
|
|
|
|
_sync_frame = 0;
|
|
@@ -1396,13 +1396,13 @@ void NetworkClientSendChat(NetworkAction
|
|
|
void NetworkClientSetCompanyPassword(const char *password)
|
|
|
{
|
|
|
MyClient::SendSetPassword(password);
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* Tell whether the client has team members where he/she can chat to.
|
|
|
* Tell whether the client has team members who they can chat to.
|
|
|
* @param cio client to check members of.
|
|
|
* @return true if there is at least one team member.
|
|
|
*/
|
|
|
bool NetworkClientPreferTeamChat(const NetworkClientInfo *cio)
|
|
|
{
|
|
|
/* Only companies actually playing can speak to team. Eg spectators cannot */
|