Not getting fully dark

NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Forum rules
NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

Not yet, wait for it. And it only works by watching certain cutscenes it seems ;)

William, thanks for reporting back. Awesome bug report thread...even if it took us three years to get behind it (and the bug being there for 11 years)
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

Aside from the first crystal ball vision, where else does this appear?
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

From William's reply, I guess "Batlin in Spinebreaker"
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
William55

Re: Not getting fully dark

Post by William55 »

The other times I got it to consistently trigger, I cheated to get to those spots just to test it. They are:

Looking at the Moon's Eye in the temple of Emotion (Batlin preparing his minions in Spinebreaker vision). This is fixed, just like the crystal ball Batlin/Cantra vision.

Looking at Fedabiblio's crystal ball to see what happened to Edrin/Ale still seems to trigger the bug.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

Looking at Fedabiblio's crystal ball to see what happened to Edrin/Ale still seems to trigger the bug.
could you send another savegame for this?
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
William55

Re: Not getting fully dark

Post by William55 »

No problem, sending it along now.
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

If I'm reading the Usecode behind the Edrin/Ale vision right, UI_ambient_light is not called there.

Is the vision of the Banes in White Dragon having this issue?
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

yeah, great, everywhere it worked before is now borked...
Because the other scenes do enable ambient light but do not disable it.
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

If I'm reading the Usecode behind the Edrin/Ale vision right, UI_ambient_light is not called there.
playing it with a debug exult, I can see ambient_light being set but not being unset :(
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

Is it possible the original engine handled the unsetting of the ambient_light after the vision ended?

I dug up the flags to test from a new game for some of these visions, I'll post them later.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

I've proposed a fix for it to reset ambient light after a fade out and this seems to fix it. But Marzo better look at what I did ;)
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

Fade in and fade out are used far more often.

Do you have a Windows build with that feature and the debug enabled? I'd like to tinker with it if I could.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

Marzo is looking into it atm. I have no Windows toolchain set up :(
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

I'll see about getting a macOS and Windows test binaries up tomorrow.
Marzo did great work on this (only thing that is still borked is the stupid helm of light - mostly because way back we took the easy road and made the helm of light toggle the infravision cheat).
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

If you want to test with a clean start, set the first flag listed. To repeat the vision unset the second flag.

// Set when Harnna asks you to look into her crystal ball
GAZE_INTO_CRYSTAL_BALL = 0x95, // 149

// Set when you watch the crystal ball in Harnna's house, and saw Batlin attack Cantra
VISION_OF_CANTRA = 0x8C, // 140
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

So, please test it with the recent 1.6 version and/or a snapshot as soon as these become available again (for OS X, it's already there but not yet for Windows - that is still the old version).

@KC, can't you go and fix the parrot scene for SI fixes... watching it again and again became really annoying as the last position of Edrin is not the same where Ale appears.
I remember that when I first played it I didn't quite make the connection that it turned Edrin into Ale... I thought it teleported Edrin away and then teleported Ale in...
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

Using the last 1.5 version and an older saved game I do not see a major problem with the switch from Edrin to Ale, position-wise. It looks like Ale is on target but is walking or following the next path egg. This could be due to the shape-switch not also including a STAND_THERE schedule change.

Further de-tangling of the issue is tricky because the path eggs at 876, 2379 are calling Usecode themselves (Quality 15) but I cannot tell which Usecode that is. How can I check what Usecode is called?

The main functions I can see are:
shapeCrystalBall shape#(0x207) () // 519
Func09B6 0x9B6 (var shape_to_follow, var coordinates)

Marzo noted that the Path Egg qualities aren't really documented anywhere outside the code:
http://exult.info/forum/viewtopic.php?p ... 1#p1720291
https://github.com/exult/exult/blob/176 ... e.cc#L1081

I am uncertain this is an issue, but I do see a possible problem with the Path Egg 6, Quality 5 should cause a kneel, but seems to lead Edrin to loiter briefly before he restarts the cycle at Path Egg 0. I think he should continue to Path Egg 7 instead.

I may need a Windows build with the debug options enabled, or steps on how to create that myself. In addition I think we may benefit having the stdout.txt include path egg usecode references for debugging potential future issues, since there is no way to see them using ES that I know of.
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

I just re-tested it, and saw the problem you describe. At Path Egg 3, Quality 16, Edrin also went loitering for a few seconds and restarted the Path Eggs. This put him out of position for the placement of Ale, being off by around 10 tiles.

From reading the Exult engine code I don't see why there's any Loiter involved with these qualities, unless it is in the Usecode itself.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

It's happening exactly (well almost) the same in the original.
The lightning hits when he is at pathegg #10 which is near the large rock. Even when he had walked all the patheggs he would sill not be at where Ale appears (around the smaller rock).
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

How can I check what Usecode is called by the path eggs?
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Dominus »

I have no idea :)
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

Ah, it is in npcEdrin object#(0x410) at least for his related barks. I'll dig in.

I don't see what's calling the lightning but there are calls to other functions there.
Knight Captain
Posts: 1219
Joined: Thu May 14, 2020 1:34 pm

Re: Not getting fully dark

Post by Knight Captain »

The Edrin usecode calls for fire shapes to be placed, though I have not seen these in either the DOS engine nor Exult.
Locked