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.16k stars 83 forks source link

[Win10 GTAIV Borderless Windowed] #125

Open Kevin-from-HP opened 3 years ago

Kevin-from-HP commented 3 years ago

Fresh GTAIV Complete Edition install, following Catsmakaroo's Ultimate GTAIV Install procedures, and he does not seem to have this issue but borderless windowed does not work as in:

Using .asi and .ini files only.

elishacloud commented 3 years ago

Can you upload the log file and the ini file you are using?

Kevin-from-HP commented 3 years ago

Managed to circumvent the issue: Somehow, setting fullscreen to 1 in .ini makes the game launch in borderless windowed mode.

Uploading both logs, one launch with fullscreen=0, changing settings in-game causing it to go borderless, and one launch with fullscreen=1, with game launching in borderless.

Extra info: Using it alongside DXVK, and with FusionFix and Zolika patches, which do some Borderless patching, but again, Catsmakaroo didn't seem to have this issue with the same setup. Weird.

(fullscreen 0) dxwrapper-playgtaiv.log (fullscreen 1) dxwrapper-playgtaiv.log

elishacloud commented 3 years ago

Try using this updated dxwrapper build. Make sure to update the ini file as needed.

dxwrapper.zip

Kevin-from-HP commented 3 years ago

Ty for taking a look at it, I've been getting by with Fullscreen=1 with no issues, altough I assume something's not quite right lmao

With this one game doesn't boot, as in, initial blackscreen and then stops responding. Log: dxwrapper-playgtaiv.log

elishacloud commented 3 years ago

Can you send me your ini file? What options do you have enabled? What are you trying to do?

It looks like the issue is with DDrawCompat. You may want to try disabling that.

Kevin-from-HP commented 3 years ago

My .ini is as follows:

Everything as it comes from download, except DDrawCompat = 1, DDrawCompatNoProcAffinity = 1, Anti-Aliasing = 1, Fullscreen = 1.

As I said, issue is circumvented with Fullscreen toggled, it launches in Borderless, assuming it is still working (is it working then?)

With DDrawCompat, NoProcAffinity and Fullscreen = 0, AA = 1 game launches in Borderless as it should :) Log: dxwrapper-playgtaiv.log

What does DDrawCompat do? Is this setting better than DDrawCompat and Fullscreen = 1 for GTAIV alongside DXVK? I've no idea how this works internally so idk

elishacloud commented 3 years ago

What does DDrawCompat do?

DDrawCompat is just a DirectDraw compatibility layer between the game and Windows to a improve to allow older game to function correctly on newer operating systems.

I don't know much about GTAIV, but if Fullscreen =1 does what you want then good. But from the latest log it appears that the dxwrapper is not doing anything. From searching the Internet it looks like GTAIV uses DirectX9. If that is the case than enabling DDrawCompat would do you no good since DDrawCompat only works on DirectX up to version 7.

It also appears that dxwrapper is not able to hook DirectX9 APIs. I added a fix for this and pre-configured the ini file for you.

Try this update: dxwrapper.zip

Kevin-from-HP commented 3 years ago

With this one game doesn't actually boot, not even a blackscreen. I'm starting to feel bad about this haha

Logs: NEW UPDATED Fullscr = 1 dxwrapper-playgtaiv.log NEW UPDATED FScr = 0 dxwrapper-playgtaiv.log

And for any sort of reference, a boot with the Github release, with EVERYTHING set to 0 (or as it comes): dxwrapper-playgtaiv.log This one launching in Borderless, (assuming Wrapper is working?)

Might be dumb, but dxwrapper .dll must be used alongside the .asi?

elishacloud commented 3 years ago

With this one game doesn't actually boot, not even a blackscreen. I'm starting to feel bad about this haha

Yeah, I made a mistake with the hooking. Let me work on a fix for that.

This one launching in Borderless, (assuming Wrapper is working?)

It is not really doing much in this mode. But if this is all you need than that is fine.

Might be dumb, but dxwrapper .dll must be used alongside the .asi?

No. You only need either the .dll or the .asi, not both.

elishacloud commented 3 years ago

Ok, I think I fixed the hooking issue. Please try with the testing build below.

Updated testing build: dxwrapper.zip

Kevin-from-HP commented 3 years ago

Ok, I've only changed fullscreen to 0 from the .ini. I'm going to assume it's working, but it breaks some stuff ingame, as the map menu is missing textures and theres a weird square around the minimap.

2

1

Log: dxwrapper-playgtaiv.log

elishacloud commented 3 years ago

I suspect that is because of the AntiAliasing option. Forcing antialiasing on games that don't support it can, in some cases, lead to these types of issues. Try disabling AntiAliasing.

Edit: If you want to use antialiasing I recommend using ReShade.

Kevin-from-HP commented 3 years ago

Yep yep yep, everything seems fine now (launching in borderless too), here's a log anyway dxwrapper-playgtaiv.log

elishacloud commented 3 years ago

Perfect. Thanks for helping troubleshoot this.

AgentHitman47 commented 5 months ago

Bro where is that "Fullscreen" in .ini file? There's "BorderlessWindowed" and "BlackscreenFix" but I couldn't find that "Fullscreen" which I can change to 0. IMG_20240131_214348

IMG_20240131_214625 IMG_20240131_214614 IMG_20240131_214606 IMG_20240131_214552 IMG_20240131_214540 IMG_20240131_214528 IMG_20240131_214510 IMG_20240131_214458 IMG_20240131_214440 IMG_20240131_214408 to 0. IMG_20240131_214707 IMG_20240131_214657 IMG_20240131_214645 IMG_20240131_214635

elishacloud commented 5 months ago

The "Fullscreen" in .ini file is in the dxwrapper.ini file not in the ZolikaPatch.ini file.

AgentHitman47 commented 5 months ago

But the disclaimer doesn't even end. It remains still. Screenshot_2024-02-01-12-42-09-79_b6022cb7d1a61f21e4fe914c8728a54c

AgentHitman47 commented 5 months ago

Well, the disclaimer issue got fixed but still facing the same black screen problem. Screenshot_2024-02-01-12-53-09-29_b6022cb7d1a61f21e4fe914c8728a54c

elishacloud commented 5 months ago

Can you upload the dxwrapper log file and ini file?

AgentHitman47 commented 5 months ago

dxwrapper-playgtaiv.log dxwrapper.zip I downloaded the zip file which you gave and the log file which Kevin-from-HP gave.

AgentHitman47 commented 5 months ago

Btw GTA 4 only runs when I download Zolika patch. Otherwise the game doesn't open. The Black screen issue is because of Zolika patch. Which version of Zolika patch did you download and how did you manage to get the game run without black screen? Screenshot_2024-02-02-14-38-24-29_40deb401b9ffe8e1df2f1cc5ba480b12 Screenshot_2024-02-02-14-38-32-44_40deb401b9ffe8e1df2f1cc5ba480b12 Screenshot_2024-02-02-14-38-39-75_40deb401b9ffe8e1df2f1cc5ba480b12 Screenshot_2024-02-02-14-38-50-04_40deb401b9ffe8e1df2f1cc5ba480b12 Screenshot_2024-02-02-14-38-57-41_40deb401b9ffe8e1df2f1cc5ba480b12

AgentHitman47 commented 5 months ago

Btw I downloaded only GTA 4 Niko Bellic edition or main edition whatever you call it, not the complete edition.