Page 1 of 1

r156 Dynamic light duration

Posted: Wed Aug 13, 2008 1:14
by Enjay
There is something screwy going on with dynamic lights. I'm not exactly sure what the problem is but it has messed with a few of my own definitions and it can also be seen in some of the standard Doom definitions.

Somewhere that is fairly easy to spot it is with the bullet puff. With older versions, fire a weapon (I suggest the SSG) at a wall and you should get brief flashes of dynamic light whilst the sprites with yellow on them are showing. By the time the bullet puff is no more than grey smoke, the dynamic lights should be gone. Do this with r156 and the light seems to last for the duration of the actor. I checked and the DECORATE and light definitions for the puffs have not changed so it must be something engine-side. I first noticed this with my own bullet puffs because their dynamic flash is shorter than the default but their smoke is longer lived so it was very obvious that something was wrong. However, the originals do still show the problem, just not as blatantly.

Like I said, I've noticed it with a few of my other actors too. One, I think, has no light on its first frame but has some later on (it's a flashing light that goes through no light, dull light, bright light, dull light, repeat). I'm not sure (because of the test level that it is in) but I think it shows no dynamic light at all now.

Posted: Wed Aug 13, 2008 1:29
by Enjay
OK, by way of an example, I've cut out and pasted the actor I was talking about.

Just load up the zip in older versions and you should see a red dynamic light flash on and off around the sprite (it looks better in my version because I also use a model with an appropriately changing skin rather than the sprite - but that's irrelevant right now).

Anyway, load it up in r156 and the dynamic light won't happen.

Posted: Wed Aug 13, 2008 1:38
by Gez
It sounds as if the actor keeps for all frames the dynamic light attached to its first frame.

Posted: Wed Aug 13, 2008 10:17
by Graf Zahl
fixed. I did some changes to the SetState function yesterday and when copying them over from ZDoom I deleted the line that updates the lights.