X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fg_options.pas;h=7aea70fc0a5f9add839ce28ab3bfe334a975fc9f;hb=96433b6928f0d3de3a7bb69b97008b17bff22b58;hp=116e6474fd136810e16de5b09963901a06c7b65b;hpb=ff17260e083bdf4461154b916a716cd9b61126b1;p=d2df-sdl.git diff --git a/src/game/g_options.pas b/src/game/g_options.pas index 116e647..7aea70f 100644 --- a/src/game/g_options.pas +++ b/src/game/g_options.pas @@ -22,7 +22,8 @@ uses function GenPlayerName (n: Integer): String; -procedure g_Options_SetDefault(); +procedure g_Options_SetDefault; +procedure g_Options_SetDefaultVideo; procedure g_Options_Read(FileName: String); procedure g_Options_Write(FileName: String); procedure g_Options_Write_Language(FileName: String); @@ -91,6 +92,7 @@ var gSFSFastMode: Boolean; gDefaultMegawadStart: AnsiString; gBerserkAutoswitch: Boolean; + glNPOTOverride: Boolean = false; implementation @@ -120,9 +122,10 @@ uses {$IFDEF USE_SDL2} procedure g_Options_SetDefaultVideo; -var - target, closest, display: TSDL_DisplayMode; - percentage: Integer; + var display: TSDL_DisplayMode; + {$IFNDEF ANDROID} + var target, closest: TSDL_DisplayMode; percentage: Integer; + {$ENDIF} begin (* Display 0 = Primary display *) gScreenWidth := 640; @@ -296,7 +299,7 @@ begin (* section MasterServer *) NetSlistIP := 'mpms.doom2d.org'; NetSlistPort := 25665; - g_Net_Slist_Set(NetSlistIP, NetSlistPort); + g_Net_Slist_Set(NetSlistIP, NetSlistPort, NetSlistList); (* section Server *) NetServerName := 'Unnamed Server'; @@ -380,7 +383,7 @@ begin ReadInteger(gFreq, 'Freq', 0); ReadBoolean(gVSync, 'VSync'); ReadBoolean(gTextureFilter, 'TextureFilter'); - ReadBoolean(glLegacyNPOT, 'LegacyCompatible'); + ReadBoolean(glNPOTOverride, 'LegacyCompatibleForce'); section := 'Sound'; ReadBoolean(gNoSound, 'NoSound'); @@ -518,7 +521,8 @@ begin section := 'MasterServer'; ReadString(NetSlistIP, 'IP'); ReadInteger(NetSlistPort, 'Port', 0, 65535); - g_Net_Slist_Set(NetSlistIP, NetSlistPort); + ReadString(NetSlistList, 'List'); + g_Net_Slist_Set(NetSlistIP, NetSlistPort, NetSlistList); section := 'Server'; ReadString(NetServerName, 'Name'); @@ -563,7 +567,7 @@ begin config.WriteInt('Video', 'BPP', gBPP); config.WriteBool('Video', 'VSync', gVSync); config.WriteBool('Video', 'TextureFilter', gTextureFilter); - config.WriteBool('Video', 'LegacyCompatible', glLegacyNPOT); + config.WriteBool('Video', 'LegacyCompatibleForce', glNPOTOverride); config.WriteBool('Sound', 'NoSound', gNoSound); config.WriteInt('Sound', 'SoundLevel', gSoundLevel); @@ -655,6 +659,7 @@ begin config.WriteStr('MasterServer', 'IP', NetSlistIP); config.WriteInt('MasterServer', 'Port', NetSlistPort); + config.WriteStr('MasterServer', 'List', NetSlistList); config.WriteStr ('Server', 'Name', NetServerName); config.WriteStr ('Server', 'Password', NetPassword);