I am attempting to make my object continuously face the camera on the Y axis, similar to how a person would turn in circles as the camera moves.
Here is the code snippet I have tested so far:
var render = function() {
animationFrameId = window.requestAnimationFrame( render);
obj.lookAt(camera.position);
obj.rotation.set(0, obj.rotation.y, 0);
}
However, I seem to be overlooking some fundamental math or trigonometry calculations because during rotation, there comes a point where the object 'jumps' and faces the wrong direction.