diff --git a/src/dllmain.cpp b/src/dllmain.cpp index 207cb45..839d64d 100644 --- a/src/dllmain.cpp +++ b/src/dllmain.cpp @@ -5,6 +5,16 @@ BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserv { if (ul_reason_for_call == DLL_PROCESS_ATTACH) { + const auto value = *reinterpret_cast(0x20600000); + if (value != 0x77E0B164) + { + printf("\x1b[31m\n**************************************************************************************\n\n"); + printf("This version of \x1b[33miw5-gsc-utils\x1b[31m is outdated.\n"); + printf("Download the latest dll from here:\x1b[34m https://github.com/fedddddd/iw5-gsc-utils/releases\ \x1b[31m\n"); + printf("\n**************************************************************************************\n\n\x1b[37m"); + return FALSE; + } + component_loader::post_unpack(); } diff --git a/src/stdinc.hpp b/src/stdinc.hpp index 2e84379..4438cfe 100644 --- a/src/stdinc.hpp +++ b/src/stdinc.hpp @@ -2,8 +2,10 @@ #pragma warning(disable: 4018) #pragma warning(disable: 4146) +#pragma warning(disable: 4129) #pragma warning(disable: 4244) #pragma warning(disable: 4267) +#pragma warning(disable: 4996) #pragma warning(disable: 26812) #define DLL_EXPORT extern "C" __declspec(dllexport)