summaryrefslogtreecommitdiff
path: root/src/network
diff options
context:
space:
mode:
Diffstat (limited to 'src/network')
-rw-r--r--src/network/network_server.cpp17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/network/network_server.cpp b/src/network/network_server.cpp
index 42d5ed9d5..9e0c212ff 100644
--- a/src/network/network_server.cpp
+++ b/src/network/network_server.cpp
@@ -2100,11 +2100,18 @@ void NetworkPrintClients()
{
NetworkClientInfo *ci;
FOR_ALL_CLIENT_INFOS(ci) {
- IConsolePrintF(CC_INFO, _network_server ? "Client #%1d name: '%s' company: %1d IP: %s" : "Client #%1d name: '%s' company: %1d",
- ci->client_id,
- ci->client_name,
- ci->client_playas + (Company::IsValidID(ci->client_playas) ? 1 : 0),
- _network_server ? (ci->client_id == CLIENT_ID_SERVER ? "server" : NetworkClientSocket::GetByClientID(ci->client_id)->GetClientIP()) : "");
+ if (_network_server) {
+ IConsolePrintF(CC_INFO, "Client #%1d name: '%s' company: %1d IP: %s",
+ ci->client_id,
+ ci->client_name,
+ ci->client_playas + (Company::IsValidID(ci->client_playas) ? 1 : 0),
+ ci->client_id == CLIENT_ID_SERVER ? "server" : NetworkClientSocket::GetByClientID(ci->client_id)->GetClientIP());
+ } else {
+ IConsolePrintF(CC_INFO, "Client #%1d name: '%s' company: %1d",
+ ci->client_id,
+ ci->client_name,
+ ci->client_playas + (Company::IsValidID(ci->client_playas) ? 1 : 0));
+ }
}
}