Page 1 of 4

32-bit mode hook

Posted: Thu Jul 18, 2019 6:20 pm
by JeremyaFr
This hook enables 32-bit mode.
8-bit OPTs are converted to 32 bits and the game can load 32-bit OPTs.
The game can load 32-bit DAT images. Existing DAT images are converted to 32 bits.

Download link
xwa_hook_32bpp.zip

Known issues:
- The models can appear too dark or too bright.

Before installing, I recommend that you check that you have the latest version of the hooks. The easy way is to use XwaHooksSetup.
I also recommend that you use an updated ddraw.dll that include the commit to reduce memory usage (mine has version v1.3.7). Else the game may run out of memory and crashes in kernelbase.dll.

Re: 32-bit mode hook

Posted: Thu Jul 18, 2019 11:09 pm
by Justagai
Awesome job Jeremy!

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 1:09 am
by Bman
Great job. Will test. Maybe the Reshade topic guys can counter this issue. Illumination problem?

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 3:33 am
by ual002
Will test and report. Awesome job!

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 6:07 am
by Darksaber
With this hook the planet backgrounds look wonderful, but there is a big problem Illuminations seems to have disappeared
Image1.jpg
Image2.jpg
The floor of the Hangar is illuminated within game, but all the other textures in the hangar have had illumination applied to the opt, but are no longer illuminated, the only thing on the shuttle that should be illuminated are the engines.

There are some of use that don't like the Reshade thing, plus no amount of tweaking Reshade isn't going to sort this problem out.

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 4:14 pm
by JeremyaFr
UPDATE
I've updated the hook.

xwa_hook_32bpp_1.jpg

It seems that the textures that are illuminated and the textures that are not illuminated are inversed.

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 5:23 pm
by ual002
That seems like a definite improvement.

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 5:39 pm
by DarHan
Here’s what it looks like on my setup with the current version. All models are 8bpp.
Image

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 8:10 pm
by JeremyaFr
UPDATE
xwa_hook_32bpp_2.jpg
xwa_hook_32bpp_3.jpg

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 8:23 pm
by Darksaber
Excellent work :) It's perfect :)

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 9:29 pm
by blue_max
The second-to-last image looks much better; but why is the last image so red? Is that what you expected?

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 9:39 pm
by ual002
Its the alarm for when your mothership is taking damage.

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 10:45 pm
by blue_max
ual002 wrote:
Fri Jul 19, 2019 9:39 pm
Its the alarm for when your mothership is taking damage.
Oh OK, nevermind then. Carry on! :P

Re: 32-bit mode hook

Posted: Fri Jul 19, 2019 11:07 pm
by Bman
Well done Jeremy. This is awesome!

Yes, when mothership has it's shields down or it's hull is at certain percentage, don't recall which triggers, the alarm effect goes off. I suppose you could change the hangar's FG texture to red lights for the ceiling and so forth to match when the mission is designed to start out that way. But it probably wouldn't work dynamically during an actual mission. Say when the mothership is normal and then later takes on severe damage later on during the mission and you're back in hangar to reload torpedoes.

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 8:23 am
by JeremyaFr
You can see the red effect in Battle 2, Mission 5: Defend CRS Liberty (1B2M5G.tie).

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 8:59 am
by Darksaber
If the hargars aren't illuminated they look far too dark, but the drawback to this is when the Red alarm is in effect the rest of the hangar doesn't red I can't understand why TG made it so the floor of the hangar is permanently illuminated but they didn't do so for the rest of the hangar, but saying that the floor does have to be at a specific level for it to be highlighted, if the floor is above or below this level, it will not highlight and the shadows of the craft and object do not appear.

You can see the highlighted floor here is this image, it's not illuminated.
Image2.jpg
But this is how the hangar would look like if the walls and other textures where not illuminated, to be it look awful and would sooner see it lit up, but like I said the drawback is the Red Alarm :(

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 1:22 pm
by JeremyaFr
UPDATE

The hook now reads the brightness setting.

Level 0:
xwa_hook_32bpp_4_level0.jpg

Level 4:
xwa_hook_32bpp_5_level4.jpg

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 2:09 pm
by Darksaber
Just tested it, Wow that look much better :D

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 2:24 pm
by Bman
Very nice, thanks. Yep DS, that's what I meant to say. Didn't understand why they didn't light up ceiling either. Maybe it's the normals of the ceiling mesh and probably the red light source is shining from above the hangar mesh. Maybe if the engine could be patched so the source of light can also shine from below the floor up . . . ?

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 3:23 pm
by JeremyaFr
Yes, the lights are based on the normals.

I succeeded to apply the red light to the white parts of the textures.
xwa_hook_32bpp_6_diffuse.jpg

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 3:29 pm
by Darksaber
This just get better and better :)

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 4:11 pm
by DarHan
I just wanted to report, the departure hangar looks great with that latest version, but the “mission failed” hangar seems to still have the problem where texture illumination is inverted.

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 5:53 pm
by ual002
So far all the ships I've been testing seem to have better color resolution as expected. Very well done sir.

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 7:02 pm
by Darksaber
The lighting in the hangar looks great, but looking at other craft or in this case stations in game, just looking through the missions this is the first prologue mission with the Azzameen Base

This is how it look like before and after the 32 bbp hook is installed
flightscreen6.jpg
flightscreen7.jpg
flightscreen8.jpg
flightscreen9.jpg
Without the hook the lighting was never great, but you can see the structural layers of the station but after the hook has been applied the station looks flat, there is no definition to the structure anymore there is no longer any, I suppose you call it ambient lighting

Don't get me wrong the Hangar now looks fabulous, the lighting on the shuttle looks great, it pissed me off for years that the shuttle wings where always darker than they should be, but the station now look wrong :(

Re: 32-bit mode hook

Posted: Sat Jul 20, 2019 7:41 pm
by Bman
DS, does any adjustments via the game's video menu settings help with shadowing? I'm going to test with ReShade to see if there is any improvement with the models.