Dynamic DX Lighting

Miscellaneous Forums/Blitz Showcase/Dynamic DX Lighting

How so? it checks for the 2 nearest lights to the player and puts DX lights there, also I've just added an extra bit of code that dims them as you move further away (kind of like fall off).


Just thinking of things you may come up against, what I meant in my example is the nearest two lights to the player may not be the nearest light to baddie number one - infact all baddies may be nearer to other lights - means the dx light count is going to go up and potentially run out - depends on how many lights you are going to have in a room i guess.

It might be worth you trying the lightmap method too to see the difference - the shots you postest above certainly look amazing, im just thinking dx lights go through other objects, so, if your character walks in and out of a nice shadow casting from a pillar or something she wont react to that shadow - picking the lightmap pixel beneath her would give you this tho.

Another example would be where you have an iron grating in the roof with light shining through it like this:

(excuse the crude image but i just knocked it up quick to demonstrate), if you pick the lightmap underneath the character she will walk in and out of the shadows being cast giving a really cool effect and making her really look like she is there, using a dx light will light her correctly and from the right angle but wont allow her to walk in and out of the shadows.