Light viewable at certain angles

Blitz3D Forums/Blitz3D Programming/Light viewable at certain angles

I have a few lights that need to be viewable at certain angles. How could I do that?
Sidelights can be view 180 degrees facing the light.
ex. http://www.boat-ed.com/fl/course/p3-5_navigationlights.htm

I would calculate the angle of the viewer in relation to the boat, and the boats heading.

Using that info I would fade a light sprite in if its within the range you specify.

Do you have a code example?