X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fg_net.pas;h=e0450ce5131996585a0bfca24731cd7209dee79f;hb=01db5bc9165a3b94dc13d7a0962d43fa0ed6e5e6;hp=72cbb9a48d6a60d8a1bfe49fefcabe3920cba925;hpb=ac201b02f10ef558087d50f6b03b4519ab567558;p=d2df-sdl.git diff --git a/src/game/g_net.pas b/src/game/g_net.pas index 72cbb9a..e0450ce 100644 --- a/src/game/g_net.pas +++ b/src/game/g_net.pas @@ -7,7 +7,7 @@ uses e_log, e_fixedbuffer, ENet, ENetTypes, ENetPlatform, Classes; const - NET_PROTOCOL_VER = 164; + NET_PROTOCOL_VER = 166; NET_MAXCLIENTS = 24; NET_CHANS = 11; @@ -424,14 +424,15 @@ procedure g_Net_Host_CheckPings(); var ClAddr: ENetAddress; Buf: ENetBuffer; - Len, ClTime: Integer; - Ping: array [0..5] of Byte; + Len: Integer; + ClTime: Int64; + Ping: array [0..9] of Byte; NPl: Byte; begin if NetPongSock = ENET_SOCKET_NULL then Exit; Buf.data := Addr(Ping[0]); - Buf.dataLength := 6; + Buf.dataLength := 2+8; Ping[0] := 0; @@ -440,7 +441,7 @@ begin if (Ping[0] = Ord('D')) and (Ping[1] = Ord('F')) then begin - ClTime := Integer(Addr(Ping[2])^); + ClTime := Int64(Addr(Ping[2])^); e_Buffer_Clear(@NetOut); e_Buffer_Write(@NetOut, Byte(Ord('D')));