narzoul / DDrawCompat

DirectDraw and Direct3D 1-7 compatibility, performance and visual enhancements for Windows Vista, 7, 8, 10 and 11
BSD Zero Clause License
885 stars 67 forks source link

Outlaws (1997) Crashes at Menu #204

Closed OpenRift412 closed 1 year ago

OpenRift412 commented 1 year ago

Was testing DDrawCompat with Lucasarts' Outlaws and found that after the opening FMV, the game crashes almost immediately when it reaches the menu. Any idea what could be causing that?

narzoul commented 1 year ago

The GOG version works just fine for me, either in DirectDraw or Direct3D mode. Can you send a crash dump or debug logs?

OpenRift412 commented 1 year ago

It was weird, I just went to test it and the first time I launched it, it seemed to work fine, but then I launched it again and it went back to not working as soon as I got to the menu. DDrawCompat-olwin.log

narzoul commented 1 year ago

Those are only info logs. Please set LogLevel=debug in DDrawCompat.ini.

OpenRift412 commented 1 year ago

Sorry about that, here you go. DDrawCompat-olwin.log

narzoul commented 1 year ago

Doesn't seem to be related to DirectDraw. Can you get also a crash dump? See here for instructions: https://github.com/narzoul/DDrawCompat/issues/50#issuecomment-520162844

OpenRift412 commented 1 year ago

It seemed to generate 2 dumps at the same time instead for some reason. I've included both of them here: CrashDumps.zip

narzoul commented 1 year ago

Your crash is inside an exported function called StopSound in lecwave.dll while iterating through some list. From the sound of it (pun intended) it must be audio related. I'm guessing it's the usual poor memory management or uninitialized variable on the game's part. Not much I can do about it from DDrawCompat.

You can try to bypass it with the IgnoreException shim in Microsoft Application Compatibility Toolkit, using ACCESS_VIOLATION_READ as its command line argument. But it will likely cause other issues or just crash with a different error anyway.

OpenRift412 commented 1 year ago

Your crash is inside an exported function called StopSound in lecwave.dll while iterating through some list. From the sound of it (pun intended) it must be audio related. I'm guessing it's the usual poor memory management or uninitialized variable on the game's part. Not much I can do about it from DDrawCompat.

Thing is, this doesn't happen with dgVoodoo's ddraw, just DDrawCompat. If I could use the compatibility toolkit, I would, but it's not compatible with Windows 11 22H2 for some reason.

narzoul commented 1 year ago

Thing is, this doesn't happen with dgVoodoo's ddraw, just DDrawCompat.

That's the thing with random access violation issues. Any change in any software components, hardware configuration, or just different timings in repeated executions, etc. could trigger it or avoid it by luck. I started the game many times with DDrawCompat and it never happens to crash for me.

If I could use the compatibility toolkit, I would, but it's not compatible with Windows 11 22H2 for some reason.

Where did you get that? I'm on Windows 11 22H2 too and I'm using the very same IgnoreException shim for another game successfully.

OpenRift412 commented 1 year ago

If I could use the compatibility toolkit, I would, but it's not compatible with Windows 11 22H2 for some reason.

Where did you get that? I'm on Windows 11 22H2 too and I'm using the very same IgnoreException shim for another game successfully.

Could you send me a link to the version you're using?

narzoul commented 1 year ago

I installed it a long time ago, but based on the version number (10.1.22000.1) it's the Windows 11 21H2 version. It's currently near the top of "Other ADK downloads", as "Download the ADK For Windows 11": https://learn.microsoft.com/en-us/windows-hardware/get-started/adk-install#other-adk-downloads Direct link: https://go.microsoft.com/fwlink/?linkid=2165884

narzoul commented 1 year ago

It seems that lecwave.dll is only loaded if you set the sound driver to "Multimedia Sound" instead of DirectSound in the config program (olcfg.exe). Have you tried using DirectSound instead? I don't get a crash with Multimedia Sound either though.

OpenRift412 commented 1 year ago

It seems that lecwave.dll is only loaded if you set the sound driver to "Multimedia Sound" instead of DirectSound in the config program (olcfg.exe). Have you tried using DirectSound instead? I don't get a crash with Multimedia Sound either though.

Oh okay, yeah that seems to help, thanks! One problem though: loading any of the settings windows just shows a black screen.

narzoul commented 1 year ago

Which settings windows do you mean? In olcfg.exe, or the Options menu in the game? I don't see any black screen in either places though.

I'm starting to think we must have vastly different game versions or settings or something. Do you have the GOG version? If not, which patches have you installed? Please take a screenshot of your Display Configuration and Direct3D Advanced settings (if you're using that one) in olcfg.exe.

OpenRift412 commented 1 year ago

Which settings windows do you mean? In olcfg.exe, or the Options menu in the game? I don't see any black screen in either places though.

I'm starting to think we must have vastly different game versions or settings or something. Do you have the GOG version? If not, which patches have you installed? Please take a screenshot of your Display Configuration and Direct3D Advanced settings (if you're using that one) in olcfg.exe.

Okay, I just ran it and it worked, but then when I went to run it again, it just decided not to. I don't know what the deal is. Outlaws as always been kind of a pain to get working. I'm using the GOG version btw.

It seems like it only works every other time from my testing.

OpenRift412 commented 8 months ago

@narzoul

Not sure if I should make a new issue for this because it is a similar issues. The menu seems to work fine now, but when switching to the win32-based options menus (keyboard, mouse, joystick), it will only work properly half the time, and there doesn't seem to be a pattern when it does and doesn't work. When it doesn't work, it will just got to a black screen and crash.

Here's a log. I launched the game and went to the keyboard menu. It worked the first time, so I went back to the main options menu and opened it again, in which it crashed. DDrawCompat-olwin.log

NOTE: This only seems to happen in DirectDraw mode, but not in Direct3D.