elishacloud / dxwrapper

Fixes compatibility issues with older games running on Windows 10/11 by wrapping DirectX dlls. Also allows loading custom libraries with the file extension .asi into game processes.
zlib License
1.15k stars 82 forks source link

Arx Fatalis does not boot. #205

Open Speedwagen opened 1 year ago

Speedwagen commented 1 year ago

I just tried to run the DirectX 7 Wrapper provided by Kim. Here is the log for Arx Fatalis. dxwrapper-arx.log The game does not boot.

elishacloud commented 1 year ago

I got the game to boot with the latest update I just checked in. However, this game uses SetRenderTarget() which I have not implemented properly yet. Also, it uses FOURCC surface formats that have no been implemented yet.

Speedwagen commented 1 year ago

Does this render some objects invisible? I will try this out today

Speedwagen commented 1 year ago

Quick question, where are you seeing the rendertarget? Also, what settings should I be using for the .ini file?

elishacloud commented 1 year ago

rendertarget is a function that the game is calling. See code here.

Also, what settings should I be using for the .ini file?

It depends on what you want to do. But at this point the only settings in the ini file that would work would be EnableDdrawWrapper and DDrawCompat.

Speedwagen commented 1 year ago

im trying to determine the render targets for my rtx remix projects. I will try those functions now

Speedwagen commented 1 year ago

after enabling E nableDdrawWrapper and DDrawCompat I had this in my log. dxwrapper-arx.log

elishacloud commented 1 year ago

im trying to determine the render targets for my rtx remix projects.

If you are trying to use RTX Remix then you will need to enable Dd7to9 in the ini file, as RTX Remix only supports Direct3D9 and you need this setting in dxwrapper to convert the game to Direct3D9. You can disable the other settings, as only Dd7to9 is needed in this case.

However, as I mentioned before the SetRenderTarget() code in dxwrapper is not fully implemented so it is not able to fully convert all of this game to Direct3D9. If you remark out these lines and recompile the code then you can get the game to load up. However, it will have issues because remarking those lines out just disables SetRenderTarget(), which is required by this game.

Speedwagen commented 1 year ago

Ahh I see! I am using a specific version of Arx Libertatis to use for RTX remix but have been running into a problem where the interactable objects do not render. RTX remix currently only points to render target 0 so I was trying to find out which other render targets the application points to. And because of this tried to explore other potential paths such as DXWrapper to have it wrap to DirectX 9 and just maybe solve the issue.

elishacloud commented 1 year ago

As far as I know, DirectX 7 games (like Arx Fatalis) only use render target 0.

For Arx Libertatis, I am not sure what the solution is. Dxwrapper has a DirectX 9 wrapper, but it is not able to convert all the render targets to 0. It seems like it would take a lot of effort to covert a game from using multiple render targets to using only one.

You could use dxwrapper to log which Direct3D 9 render targets are used by adding some logging here. Just enable the EnableD3d9Wrapper option in the ini file for DirectX 9 games.

Speedwagen commented 1 year ago

Oh! Amazing! Thanks for your help by the way. Greatly appreciated. I will go ahead and test more games and send across log files if that helps.

elishacloud commented 1 year ago

I put an update in that allows Arx Fatalis to run without any code changes. It is still not playable as it has corrupt graphics on the main menu, at least it can start now.

Speedwagen commented 1 year ago

Oh, amazing. Thanks, I will try it when I get home tonight.

elishacloud commented 1 year ago

With the latest build if you enable the below settings the game is getting close to being playable, but still has a lot of graphical anomalies.

[Compatibility]
Dd7to9                     = 1

[d3d9]
FullscreenWindowMode       = 1
Speedwagen commented 1 year ago

wow, that is awesome. I have not had a chance to run this yet but will test as soon as I can.

Speedwagen commented 10 months ago

Hi there. I just wanted to apologise as I have not had a chance to actually take a look at the changes for this. I will actually have a look at this tonight.

elishacloud commented 10 months ago

No problem. Here is the latest build to test with. The game is still not playable, but it is further along.

Here is the test build: dxwrapper.zip

elishacloud commented 9 months ago

The game is playable with the latest build if you do the following:

  1. Disable in-game Bump Mapping and Rendering Fix
  2. Enable Dd7to9 and FullscreenWindowMode in dxwrapper

Here is the latest build: dxwrapper.zip

Speedwagen commented 8 months ago

dxwrapper-arx.log Hi, I tried to run the application with the recommended but the application would not load. I have attached the log file for you to peruse.

elishacloud commented 8 months ago

@Speedwagen, that is an old build. I never updated this thread with the latest build. However, I put a lot of fixes in since then.

The released build should work for you. Make sure you disable both the in-game options: Bump Mapping and Rendering Fix. You also need to enable Dd7to9 and FullscreenWindowMode in dxwrapper.

Note: I am using the GOG version of the game. Not sure if other versions work the same as the GOG version.

Also, make sure you disable all compatibility settings:

image

Speedwagen commented 8 months ago

I think I got it to boot. Switched to software mode and the display looks like this haha. parsecd_ebcamlJqsw dxwrapper-arx.log

elishacloud commented 3 months ago

I got most of this game to run in Direct3D mode. There are still some lighting issues, but it seems to work other than that. Here is the updated build: dxwrapper.zip

elishacloud commented 1 month ago

I fixed the color key issues. This build has almost all the issues fixed: dxwrapper.zip