summaryrefslogtreecommitdiff
path: root/src/network
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-04-18 10:16:51 +0000
committerrubidium <rubidium@openttd.org>2008-04-18 10:16:51 +0000
commit1b2773445d12037bb1293d35e5f1b9a4a44168d9 (patch)
treedfc71064bea779abeeec229e5820046f40499776 /src/network
parent2070cee0892591be5842842c1e6be41cdeda2f36 (diff)
downloadopenttd-1b2773445d12037bb1293d35e5f1b9a4a44168d9.tar.xz
(svn r12765) -Codechange: move some stuff out of variables.h that required including other headers in variables.h.
Diffstat (limited to 'src/network')
-rw-r--r--src/network/core/tcp.cpp1
-rw-r--r--src/network/network.cpp1
-rw-r--r--src/network/network_client.cpp1
3 files changed, 3 insertions, 0 deletions
diff --git a/src/network/core/tcp.cpp b/src/network/core/tcp.cpp
index a4b763b1a..f44f1741c 100644
--- a/src/network/core/tcp.cpp
+++ b/src/network/core/tcp.cpp
@@ -75,6 +75,7 @@ NetworkRecvStatus NetworkTCPSocketHandler::CloseConnection()
if (!_network_server && _networking) {
_switch_mode = SM_MENU;
_networking = false;
+ extern StringID _switch_mode_errorstr;
_switch_mode_errorstr = STR_NETWORK_ERR_LOSTCONNECTION;
return NETWORK_RECV_STATUS_CONN_LOST;
diff --git a/src/network/network.cpp b/src/network/network.cpp
index 8ec1a2a8a..26009d749 100644
--- a/src/network/network.cpp
+++ b/src/network/network.cpp
@@ -224,6 +224,7 @@ uint NetworkCalculateLag(const NetworkTCPSocketHandler *cs)
static void NetworkError(StringID error_string)
{
_switch_mode = SM_MENU;
+ extern StringID _switch_mode_errorstr;
_switch_mode_errorstr = error_string;
}
diff --git a/src/network/network_client.cpp b/src/network/network_client.cpp
index 378e6de56..abc5c6203 100644
--- a/src/network/network_client.cpp
+++ b/src/network/network_client.cpp
@@ -328,6 +328,7 @@ DEF_CLIENT_SEND_COMMAND_PARAM(PACKET_CLIENT_RCON)(const char *pass, const char *
// **********
extern bool SafeSaveOrLoad(const char *filename, int mode, int newgm, Subdirectory subdir);
+extern StringID _switch_mode_errorstr;
DEF_CLIENT_RECEIVE_COMMAND(PACKET_SERVER_FULL)
{