From e4763f3efd116e62c87b39bdfc950f9c40507843 Mon Sep 17 00:00:00 2001 From: Linventif Date: Tue, 15 Jul 2025 21:52:40 +0000 Subject: [PATCH] fix: simplify DLL installation check logic in timer function --- lua/gmod_integration/core/utils/sv_main.lua | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lua/gmod_integration/core/utils/sv_main.lua b/lua/gmod_integration/core/utils/sv_main.lua index ce1104e..8204575 100644 --- a/lua/gmod_integration/core/utils/sv_main.lua +++ b/lua/gmod_integration/core/utils/sv_main.lua @@ -9,9 +9,8 @@ function gmInte.detectOS() end timer.Create("gmInte:CheckDLL", 30, 0, function() - if !gmInte.dllInstalled() && !gmInte.debug then - print(" ") - print(gmInte.getTranslation("admin.dll_install_problem", "The Gmod Integration DLL is missing!\n\nWithout this DLL, some features will not work correctly, including authentication and advanced integration.") .. "\n\n" .. gmInte.getTranslation("admin.dll_install_description", "Install:\n1. Download 'gmsv_gmod_integration_loader_{1}.dll' from: {2}\n2. Move it to the 'garrysmod/lua/bin' folder.\n3. Restart your server.", gmInte.detectOS(), "https://github.com/gmod-integration/auto-loader/releases/latest/download/gmsv_gmod_integration_loader_" .. gmInte.detectOS() .. ".dll")) - print(" ") - end + if gmInte.dllInstalled() || gmInte.Config.debug then return end + print(" ") + print(gmInte.getTranslation("admin.dll_install_problem", "The Gmod Integration DLL is missing!\n\nWithout this DLL, some features will not work correctly, including authentication and advanced integration.") .. "\n\n" .. gmInte.getTranslation("admin.dll_install_description", "Install:\n1. Download 'gmsv_gmod_integration_loader_{1}.dll' from: {2}\n2. Move it to the 'garrysmod/lua/bin' folder.\n3. Restart your server.", gmInte.detectOS(), "https://github.com/gmod-integration/auto-loader/releases/latest/download/gmsv_gmod_integration_loader_" .. gmInte.detectOS() .. ".dll")) + print(" ") end) \ No newline at end of file