diff -r c021699c33dc -r 7d4e5ce73b98 hedgewars/uIO.pas --- a/hedgewars/uIO.pas Sat Apr 21 18:02:44 2012 +0200 +++ b/hedgewars/uIO.pas Sat Apr 21 20:12:22 2012 +0400 @@ -26,6 +26,7 @@ procedure freeModule; procedure SendIPC(s: shortstring); +procedure SendIPCc(c: char); procedure SendIPCXY(cmd: char; X, Y: SmallInt); procedure SendIPCRaw(p: pointer; len: Longword); procedure SendIPCAndWaitReply(s: shortstring); @@ -123,7 +124,7 @@ begin case s[1] of '!': begin AddFileLog('Ping? Pong!'); isPonged:= true; end; - '?': SendIPC('!'); + '?': SendIPCc('!'); 'e': ParseCommand(copy(s, 2, Length(s) - 1), true); 'E': OutError(copy(s, 2, Length(s) - 1), true); 'W': OutError(copy(s, 2, Length(s) - 1), false); @@ -229,6 +230,14 @@ end end; +procedure SendIPCc(c: char); +var s: shortstring; +begin + s[0]:= #0; + s[1]:= c; + SendIPC(s); +end; + procedure SendIPCRaw(p: pointer; len: Longword); begin if IPCSock <> nil then @@ -259,7 +268,7 @@ procedure SendIPCAndWaitReply(s: shortstring); begin SendIPC(s); -SendIPC('?'); +SendIPCc('?'); IPCWaitPongEvent end; @@ -267,7 +276,7 @@ begin inc(SendEmptyPacketTicks, Lag); if (SendEmptyPacketTicks >= cSendEmptyPacketTime) then - SendIPC('+') + SendIPCc('+') end; procedure NetGetNextCmd;