X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fg_net.pas;h=45f507a53dcccadfe604224d5fccaa1f90f7666d;hb=847038a14751d192fcc4af172d7a963e28144c72;hp=7dad24c613d1a30243f263f945b77e714f783353;hpb=bb118168f4465ea81396ae6bbf2c11baaba6539e;p=d2df-sdl.git diff --git a/src/game/g_net.pas b/src/game/g_net.pas index 7dad24c..45f507a 100644 --- a/src/game/g_net.pas +++ b/src/game/g_net.pas @@ -21,7 +21,7 @@ uses e_log, e_msg, utils, ENet, Classes, md5, MAPDEF{$IFDEF USE_MINIUPNPC}, miniupnpc;{$ELSE};{$ENDIF} const - NET_PROTOCOL_VER = 185; + NET_PROTOCOL_VER = 186; NET_MAXCLIENTS = 24; NET_CHANS = 12; @@ -172,6 +172,8 @@ var NetGotEverything: Boolean = False; NetGotKeys: Boolean = False; + NetDeafLevel: Integer = 0; + {$IFDEF USE_MINIUPNPC} NetPortForwarded: Word = 0; NetPongForwarded: Boolean = False; @@ -271,7 +273,10 @@ begin end; procedure g_Net_InitLowLevel (); + var v: ENetVersion; begin + v := enet_linked_version(); + e_LogWritefln('ENet Version: %s.%s.%s', [ENET_VERSION_GET_MAJOR(v), ENET_VERSION_GET_MINOR(v), ENET_VERSION_GET_PATCH(v)]); if enet_init_success then raise Exception.Create('wuta?!'); enet_init_success := (enet_initialize() = 0); end; @@ -2439,6 +2444,7 @@ initialization conRegVar('cl_interp', @NetInterpLevel, '', 'net player interpolation steps'); conRegVar('cl_last_ip', @NetClientIP, '', 'address of the last you have connected to'); conRegVar('cl_last_port', @NetClientPort, '', 'port of the last server you have connected to'); + conRegVar('cl_deafen', @NetDeafLevel, '', 'filter server messages (0-3)'); conRegVar('sv_forwardports', @NetForwardPorts, '', 'forward server port using miniupnpc (requires server restart)'); conRegVar('sv_rcon', @NetAllowRCON, '', 'enable remote console');