1
0
mirror of https://github.com/FunkyFr3sh/cnc-ddraw.git synced 2025-03-14 22:03:27 +01:00

add support for Die by the Sword

This commit is contained in:
FunkyFr3sh 2024-12-18 07:34:36 +01:00
parent 7af3be82e3
commit d1338fd92a
3 changed files with 8 additions and 4 deletions

View File

@ -846,6 +846,10 @@ static void cfg_create_ini()
"resolutions=2\n"
"singlecpu=false\n"
"\n"
"; Die by the Sword\n"
"[windie]\n"
"maxgameticks=30\n"
"\n"
"; Dragon Throne: Battle of Red Cliffs\n"
"[AdSanguo]\n"
"maxgameticks=60\n"

View File

@ -1549,8 +1549,8 @@ HRESULT dd_SetCooperativeLevel(HWND hwnd, DWORD dwFlags)
{
TRACE(" client rect=%dx%d\n", rc.right, rc.bottom);
g_ddraw.windowed_hack = TRUE;
dd_SetDisplayMode(rc.right, rc.bottom, 16, 0);
//g_ddraw.windowed_hack = TRUE;
//dd_SetDisplayMode(rc.right, rc.bottom, 16, 0);
}
}
}

View File

@ -58,9 +58,9 @@ static HRESULT WINAPI fake_did_SetCooperativeLevel(IDirectInputDeviceA* This, HW
TRACE(" mouse_device = %s\n", This == g_mouse_device ? "TRUE" : "FALSE");
dbg_dump_di_scm_flags(dwFlags);
if (This == g_mouse_device && g_ddraw.ref && (dwFlags & DISCL_EXCLUSIVE))
if (This == g_mouse_device && (dwFlags & DISCL_EXCLUSIVE))
{
if (g_mouse_locked || g_config.devmode)
if (g_mouse_locked || g_config.devmode || !g_ddraw.ref)
{
while (real_ShowCursor(FALSE) >= 0);
}