Character Shadows

Blitz3D Forums/Blitz3D Programming/Character Shadows

"Will it cast shadows from alpha tranparencies"

Hm...

I believe the answer is yes and no.

When casting a normal shadow, a copy of the mesh casting the shadow is made, and textured black and then a texture is made from the view of the light source. This would override any texture with alpha you have on the model.

However, there is a special shadow type for casitng shaodws from translucent objects, like colored glass. In this mode the model is NOT retextured. However, this means that the model will then cast a colored shadow as if it were fully transparent. But there will be uncolored holes where the alpha is.

There is a potential solution though. You could cast a shadow from a hidden entity. I forget if the system checks to see whether the entity is hidden or not before castign a shadow but it would be a trivial change to an if statement in the system that I could make for you if it did not. This hidden entity would be a copy of the entity you make, which is colored black but has alpha transparency. You then would use the colored shadow mode and the result would appear to be a shadow coming from the original object.


Copper:
There is no such thing s "true" shadows. Only various algorithms which approximate some things better than others. The shadows in Doom 3 have major limitations as well. All the characters have to be very low polygon for example. And a bunch of shadows which are cast across your viewpoint, such as the shadows from a jail cell door when viewed side on, kill the framerate.

Also more advanced techniques require more advanced hardware, and the nice thing about Blitz is that your game will look the same without any affort on your part on even the lowest end generic 3D hardware (in general). Though the framerate may not be spectacular.