From f735e7a0364bf4fa6401aca7cfc720467ef81fb4 Mon Sep 17 00:00:00 2001 From: Er2 Date: Sat, 14 Jan 2023 20:47:16 +0300 Subject: [PATCH] Fix HTML MOTD (#174) --- game/client/game_controls/vguitextwindow.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/game/client/game_controls/vguitextwindow.cpp b/game/client/game_controls/vguitextwindow.cpp index 4967d74a..203f6ccd 100644 --- a/game/client/game_controls/vguitextwindow.cpp +++ b/game/client/game_controls/vguitextwindow.cpp @@ -32,7 +32,7 @@ extern INetworkStringTable *g_pStringTableInfoPanel; #define TEMP_HTML_FILE "textwindow_temp.html" -ConVar cl_disablehtmlmotd( "cl_disablehtmlmotd", "0", FCVAR_ARCHIVE, "Disable HTML motds." ); +ConVar cl_disablehtmlmotd( "cl_disablehtmlmotd", "1", FCVAR_ARCHIVE, "Disable HTML motds." ); //============================================================================= // HPE_BEGIN: @@ -129,7 +129,8 @@ void CTextWindow::ApplySchemeSettings( IScheme *pScheme ) CTextWindow::~CTextWindow() { // remove temp file again - g_pFullFileSystem->RemoveFile( TEMP_HTML_FILE, "DEFAULT_WRITE_PATH" ); + if (g_pFullFileSystem->FileExists(TEMP_HTML_FILE)) + g_pFullFileSystem->RemoveFile( TEMP_HTML_FILE, "DEFAULT_WRITE_PATH" ); } void CTextWindow::Reset( void )