summaryrefslogtreecommitdiff
path: root/players.c
diff options
context:
space:
mode:
Diffstat (limited to 'players.c')
-rw-r--r--players.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/players.c b/players.c
index 1bccd06c2..86feeb944 100644
--- a/players.c
+++ b/players.c
@@ -653,8 +653,11 @@ int32 CmdPlayerCtrl(int x, int y, uint32 flags, uint32 p1, uint32 p2)
if (p != NULL) {
if (_local_player == OWNER_SPECTATOR) {
- _local_player = p->index;
- MarkWholeScreenDirty();
+ /* Check if we do not want to be a spectator in network */
+ if (!_networking || _network_server || _network_playas != OWNER_SPECTATOR) {
+ _local_player = p->index;
+ MarkWholeScreenDirty();
+ }
}
#ifdef ENABLE_NETWORK
if (_network_server) {