I'm looking to create a dynamic spotlight that moves along with the camera. The code I have currently only maintains the spotlight at the exact position of the camera:
var pointLight = new THREE.PointLight( 0xffffff, 1, 200 );
pointLight.position = camera.position;
scene.add(pointLight);
Is there a way to update this code so that the spotlight is constantly positioned in front of the camera by a set distance? Or essentially, always maintaining a specific relationship to the camera's position?