diff options
| author | Michal Zima <xhire@mujmalysvet.cz> | 2009-12-06 22:58:26 +0100 |
|---|---|---|
| committer | Michal Zima <xhire@mujmalysvet.cz> | 2009-12-06 22:58:26 +0100 |
| commit | 753131cf9b32315fdd11f2ce6e58b8f2d6ba3bc1 (patch) | |
| tree | cfbded574ded7c3c666de6211877469ff6a95d75 /src/client/client.c | |
| parent | a0939379bb1185ee6d66739d9d021466d5d89624 (diff) | |
Revised methods how are translated strings handled
Few comments were made available to Doxygen
Diffstat (limited to 'src/client/client.c')
| -rw-r--r-- | src/client/client.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/client/client.c b/src/client/client.c index 13d9964..054b3ea 100644 --- a/src/client/client.c +++ b/src/client/client.c @@ -95,7 +95,7 @@ static int initUdpClient(char *ip, int port) return -1; } - DEBUG_MSG(_("[Debug] Connected to game server [%s]:[%d]\n"), ip, port); + debug("Connected to game server [%s]:[%d]", ip, port); return 0; } @@ -132,8 +132,8 @@ int client_init(char *ip, int port) static void errorWithServer() { - fprintf(stderr, _("[Error] Game server is not responding\n")); - analyze_set_msg(_("[Error] Unable to connect to the game server")); + error("Game server is not responding"); + analyze_set_msg(_("Unable to connect to the game server")); world_do_end(); } @@ -146,7 +146,7 @@ void client_send(char *msg) ret = -1; if (isParamFlag("--send")) { - printf(_("[Debug] Sending data: %s"), msg); + debug("Sending data: %s", msg); } #ifdef SUPPORT_TRAFFIC @@ -204,7 +204,7 @@ static void client_eventWorkRecvList() protoCmd = findCmdProto(line); if (isParamFlag("--recv")) { - printf(_("[Debug] Recieved data: %s"), line); + debug("Recieved data: %s", line); } if (protoCmd != NULL) { @@ -295,7 +295,7 @@ static void eventTraffic() if (currentTime - lastTraffic > 5000) { lastTraffic = currentTime; - DEBUG_MSG(_("[Debug] Traffic: down [%d]/up [%d]\n"), traffic_down, traffic_up); + debug("Traffic: down [%d]/up [%d]", traffic_down, traffic_up); traffic_down = 0; traffic_up = 0; @@ -312,7 +312,6 @@ void client_event() eventPingServer(); selectClientSocket(); client_eventWorkRecvList(); - } static void quitUdpClient() @@ -320,7 +319,7 @@ static void quitUdpClient() assert(sock_server_udp != NULL); sock_udp_close(sock_server_udp); - DEBUG_MSG(_("[Debug] Closing connection to game server\n")); + debug("Closing connection to game server"); } void client_quit() |