X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fg_options.pas;h=37aac9da3d198269795ff608afd161a840d84d41;hb=d7d166dc3cd287276202e862746208892c4cc89f;hp=9009078742262d6ccedecc5b19ca7a49cedc9af4;hpb=d9caec42f4065225160a661e0115677b51e67d6a;p=d2df-sdl.git diff --git a/src/game/g_options.pas b/src/game/g_options.pas index 9009078..37aac9d 100644 --- a/src/game/g_options.pas +++ b/src/game/g_options.pas @@ -129,12 +129,13 @@ var gSFSDebug: Boolean = False; gSFSFastMode: Boolean = False; gDefaultMegawadStart: AnsiString = DF_Default_Megawad_Start; + gBerserkAutoswitch: Boolean = True; implementation uses e_log, e_input, g_window, g_sound, g_gfx, g_player, Math, - g_map, g_net, g_netmaster, SysUtils, CONFIG, g_game, g_main, e_textures, + g_map, g_net, g_netmaster, SysUtils, CONFIG, g_game, g_main, e_texture, g_items, GL, GLExt, wadreader, e_graphics; procedure g_Options_SetDefault(); @@ -260,11 +261,11 @@ var i: Integer; begin gAskLanguage := True; - e_WriteLog('Reading config', MSG_NOTIFY); + e_WriteLog('Reading config', TMsgType.Notify); if not FileExists(FileName) then begin - e_WriteLog('Config file '+FileName+' not found', MSG_WARNING); + e_WriteLog('Config file '+FileName+' not found', TMsgType.Warning); g_Options_SetDefault(); // Default video options: @@ -436,6 +437,7 @@ begin wadoptFast := gSFSFastMode; e_FastScreenshots := config.ReadBool('Game', 'FastScreenshots', True); gDefaultMegawadStart := config.ReadStr('Game', 'DefaultMegawadStart', 'megawads/DOOM2D.WAD:\MAP01'); + gBerserkAutoswitch := config.ReadBool('Game', 'BerserkAutoswitch', False); // Ãåéìïëåé â ñâîåé èãðå gcMap := config.ReadStr('GameplayCustom', 'Map', ''); @@ -527,10 +529,7 @@ begin config.Free(); - if gTextureFilter then - TEXTUREFILTER := GL_LINEAR - else - TEXTUREFILTER := GL_NEAREST; + //if gTextureFilter then TEXTUREFILTER := GL_LINEAR else TEXTUREFILTER := GL_NEAREST; end; procedure g_Options_Write(FileName: String); @@ -538,7 +537,7 @@ var config: TConfig; i: Integer; begin - e_WriteLog('Writing config', MSG_NOTIFY); + e_WriteLog('Writing config', TMsgType.Notify); config := TConfig.CreateFile(FileName); @@ -673,6 +672,7 @@ begin config.WriteBool('Game', 'SFSFastMode', gSFSFastMode); config.WriteBool('Game', 'FastScreenshots', e_FastScreenshots); config.WriteStr('Game', 'DefaultMegawadStart', gDefaultMegawadStart); + config.WriteBool('Game', 'BerserkAutoswitch', gBerserkAutoswitch); config.WriteStr ('GameplayCustom', 'Map', gcMap); config.WriteStr ('GameplayCustom', 'GameMode', gcGameMode); @@ -726,7 +726,7 @@ procedure g_Options_Write_Language(FileName: String); var config: TConfig; begin - e_WriteLog('Writing language config', MSG_NOTIFY); + e_WriteLog('Writing language config', TMsgType.Notify); config := TConfig.CreateFile(FileName); config.WriteStr('Game', 'Language', gLanguage); @@ -739,7 +739,7 @@ var config: TConfig; sW, sH: Integer; begin - e_WriteLog('Writing resolution to config', MSG_NOTIFY); + e_WriteLog('Writing resolution to config', TMsgType.Notify); config := TConfig.CreateFile(FileName); @@ -769,7 +769,7 @@ procedure g_Options_Write_Gameplay_Custom(FileName: String); var config: TConfig; begin - e_WriteLog('Writing custom gameplay config', MSG_NOTIFY); + e_WriteLog('Writing custom gameplay config', TMsgType.Notify); config := TConfig.CreateFile(FileName); @@ -793,7 +793,7 @@ procedure g_Options_Write_Gameplay_Net(FileName: String); var config: TConfig; begin - e_WriteLog('Writing network gameplay config', MSG_NOTIFY); + e_WriteLog('Writing network gameplay config', TMsgType.Notify); config := TConfig.CreateFile(FileName); @@ -817,7 +817,7 @@ procedure g_Options_Write_Net_Server(FileName: String); var config: TConfig; begin - e_WriteLog('Writing server config', MSG_NOTIFY); + e_WriteLog('Writing server config', TMsgType.Notify); config := TConfig.CreateFile(FileName); @@ -835,7 +835,7 @@ procedure g_Options_Write_Net_Client(FileName: String); var config: TConfig; begin - e_WriteLog('Writing client config', MSG_NOTIFY); + e_WriteLog('Writing client config', TMsgType.Notify); config := TConfig.CreateFile(FileName);