So, I've been searching the internet for a while and I still didn't understand how to create a flashlight's "circle" in front of the camera over other objects.
I found the following links:
And they give me examples and solutions about how to draw lights or other effects on objects.
But it's not clear to me yet. I'm newbie with HLSL (and still a little with XNA itself) and I don't get what should I do. I need help with the steps I should take to modify my HLSL effect* of the voxel engine to draw a white circle where the cursor points and shine the light around the camera position as the flashlight is on.
*I created a voxel engine that uses a effect (modified a little) I found in a project called TechCraft. It changes the light on the map depending of the time of the day and the sun position. But I'm not sure how it works neither, I just read a little but I'm not used to HLSL as I said. (Where could I find good HLSL tutorials?)
Do I need to make many passes and make a pixel shader and a vertex shader for each one? Or should I create many techniques? What's the difference?
Or is that a bad idea? Should I create another effect and draw again the voxel with its technique and pass?
And maybe it's not only one light. If I'm able to create a multiplayer someday, or NPCs, the game will have more than one light on at the same time. How to draw more than one circle?
I'm really lost with this, and I have no idea where should I start from. I appreciate any help; even showing already answered questions is helpful to me.