Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: danthat on Fri 05/08/2011 10:23:36

Title: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Fri 05/08/2011 10:23:36
Hello! I'm updating Time Gentlemen, Please! Somewhere along the line, I've updated it from what it was made in (3.0, I think) to the latest, 3.2.1

I'm suddenly seeing a weird lighting issue - the region they're standing on has an initial lightLevel of 40. Once you open the panel to the left, it's set in-script to 90 (region[3].LightLevel = 90)

(http://sizefivegames.com/uploads/TGP_light.PNG)

The contrast on the characters is suddenly way up. Has something else changed somewhere I'm not aware of? Reading around, I think character.Tint has some new parameters and may be part of the problem.

Any suggestions?

Cheers,

Dan

Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.1.2?
Post by: monkey0506 on Fri 05/08/2011 11:18:23
I just checked and the parameter list for Character.Tint hasn't changed since at least AGS 2.72 (possibly earlier), though I do seem to recall something of a bug having been reported regarding the way tint levels were being applied (maybe, I might be imagining that!).

One thought I had though, have you per chance changed from the DirectDraw 5 to DirectX 9 driver in Game Settings? I definitely remember there being discrepancies between the drivers.
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.1.2?
Post by: danthat on Fri 05/08/2011 13:51:13
My mistake - got the numbers wrong. I'm now using 3.2.1, don't know if that makes a difference.

Definitely using DX9 for display, which is how it always was and always worked.

Recompiling with 3.1 this issue doesn't exist, so it's definitely something that's changed with 3.2.1.
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Sun 07/08/2011 13:01:23
I've been fiddling with this for hours now, and found no way around it.

Anyone know of a reason why this behaviour might be happening? Is it a bug?
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: Calin Leafshade on Sun 07/08/2011 13:35:58
The D3D driver tint shader was changed for version 3.2.1 to deal with a bug. It's possible that that may have introduced a new bug with certain values.
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Mon 08/08/2011 10:48:55
Any chance a mod could shift this into Technical? I'm pretty sure this is an issue. I've exhausted every workaround I can think of... :(
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: monkey0506 on Tue 09/08/2011 02:14:31
Could you verify if the same issue is present in 3.2? It is possible that the changes Calin is talking about are the root cause of your issue.
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Tue 09/08/2011 10:54:05
I can't find a link to 3.2 on the download page... am I missing a link?
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: Khris on Tue 09/08/2011 11:00:52
There's one here:
http://www.agsarchives.com/engine/archive.html
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Tue 09/08/2011 15:12:31
Thank you!

Problem still exists in v3.2 though, I'm afraid...
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: danthat on Tue 09/08/2011 15:25:32
Hmmm. Is this just a disparity between editor-side and script-side code?

In editor a light level of 40 is low, 90 is high. If I just set the light level to 20, it renders it marginally higher, and looks right.

So there *is* a workaround, it's just not ideal?
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: Calin Leafshade on Tue 09/08/2011 16:11:32
I find it hard to believe that this bug has slipped through unnoticed. People use region light level all the time.

Are you sure you arent doing anything odd?
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: Khris on Tue 09/08/2011 16:50:44
Could this maybe be caused by the bit depth of the sprites?
I remember testing light levels for the first time with the Roger character and it was all screwed up due to the sprites not being 16bit ones.
Title: Re: region.Lightlevel brightness issue- change from v3.0 to v3.2.1?
Post by: Calin Leafshade on Tue 09/08/2011 17:13:41
Yea, I thought the same actually.

Did the upgrade process fuck with your bit depth settings?