summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-03-30 22:37:45 +0000
committerrubidium <rubidium@openttd.org>2010-03-30 22:37:45 +0000
commitf97a41040f78da55191a709d2861202dfd66e77c (patch)
treeb7ed076b6d2500ae6f332922e9b736cd63c31ac6 /src
parent02fb92dc83d5311f132c9f7d4f98dbdb407335fa (diff)
downloadopenttd-f97a41040f78da55191a709d2861202dfd66e77c.tar.xz
(svn r19526) -Fix (r19395): clients would crash while connecting to a server with AIs
Diffstat (limited to 'src')
-rw-r--r--src/ai/ai_gui.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/ai/ai_gui.cpp b/src/ai/ai_gui.cpp
index a297f74aa..28c514a74 100644
--- a/src/ai/ai_gui.cpp
+++ b/src/ai/ai_gui.cpp
@@ -1028,6 +1028,9 @@ void InitializeAIGui()
/** Open the AI debug window if one of the AI scripts has crashed. */
void ShowAIDebugWindowIfAIError()
{
+ /* Network clients can't debug AIs. */
+ if (_networking && !_network_server) return;
+
Company *c;
FOR_ALL_COMPANIES(c) {
if (c->is_ai && c->ai_instance->IsDead()) {