diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2015-04-04 23:32:01 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2015-04-04 23:32:01 +0200 |
commit | 7bf6dbfed060ded89da8c53ae8b712e62bd19da2 (patch) | |
tree | cd7b6e4970194f6288b7a5980b4c89426306c469 /src/game/g_active.c | |
parent | f6e33b770e9fd1b5e6024c96ebd6f8183cc25a83 (diff) |
Fix a bug in G_SendPublicServerCommand.
Diffstat (limited to 'src/game/g_active.c')
-rw-r--r-- | src/game/g_active.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game/g_active.c b/src/game/g_active.c index 7148af0..02cb6e9 100644 --- a/src/game/g_active.c +++ b/src/game/g_active.c @@ -2223,14 +2223,14 @@ void G_SendPublicServerCommand( int clientNum, const char *cmd ) int i; gclient_t *client; - for( i = 0; i < level.maxclients ; i++ ) + for( i = 0; i < level.maxclients; i++ ) { client = level.clients + i; if( client->pers.connected != CON_CONNECTED ) continue; - if( client->ps.clientNum == clientNum ) + if( i == clientNum ) goto send; if( client->sess.spectatorState == SPECTATOR_NOT ) @@ -2240,7 +2240,7 @@ void G_SendPublicServerCommand( int clientNum, const char *cmd ) continue; send: - trap_SendServerCommand( client->ps.clientNum, cmd ); + trap_SendServerCommand( i, cmd ); } } |