1
0
mirror of https://github.com/FunkyFr3sh/cnc-ddraw.git synced 2025-03-15 06:04:49 +01:00

set g_ddraw_module right away

This commit is contained in:
FunkyFr3sh 2024-02-17 18:11:58 +01:00
parent 194fb5e371
commit caa06c77c0

View File

@ -26,6 +26,8 @@ BOOL WINAPI DllMain(HANDLE hDll, DWORD dwReason, LPVOID lpReserved)
{
case DLL_PROCESS_ATTACH:
{
g_ddraw_module = hDll;
if (GetEnvironmentVariableW(L"cnc_ddraw_config_init", NULL, 0))
{
cfg_load();
@ -40,8 +42,6 @@ BOOL WINAPI DllMain(HANDLE hDll, DWORD dwReason, LPVOID lpReserved)
cfg_load();
g_ddraw_module = hDll;
char buf[1024];
if (GetEnvironmentVariable("__COMPAT_LAYER", buf, sizeof(buf)))