🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Moving a spotlight

Started by
-1 comments, last by NinjaCross 24 years ago
Hy guys ! I need for a little help about a problem I found in my engine. I''m now implementing the lightning. I want that a spotlight always follows the camera (I''m doing an engine for a FPS game), pointing directly in front of its (like an electric torch). I followed all the instructions that i found on the redbook about positioning and rotating lights (using also glPushmatrix & glpopMatrix), but i cant''t find the correct way ! The spotlight is alway positioned in a displaced (translated) postion than the player positon, and it doesn''t orientate it''s self correctly. Please help me also with pieces of code !! Thanks in advance. //------------- Making Funny Garbage Codes on http://members.xoom.it/NinjaCross
//-------------A straight line may be the shortest distance between two points, but it is by no means the most interesting.http://members.xoom.it/NinjaCross

This topic is closed to new replies.

Advertisement