fake lighting

Blitz3D Forums/Blitz3D Beginners Area/fake lighting

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

For a school project, I am trying to make my own way to light a mesh. I know that this is way easy to get this effect, but I am trying to understand how blitz works and make my own function. I have tried, and got it to sort of work, but it still has issues that are confusing me a lot. Here is what I have so far. Please help me figure out how to get this working!

http://www.freewebs.com/blitznerd/lighting/lighting.zip
My lighting attempt