Forum

Mouse move -> camera/character rotation

Since my last post went in a different (but important) direction, I'm going to shift my big problem over here. I'm also going to explain in another way, hopefully making my problem clearer.

I want to know how to replace the second part of the code with manifolds so that it can be used with the first (I used semi-stiff constraint in my scene, because I want to be able to rotate the camera up and down independently of the character).

- This works for me in Chrome but not Firefox (v 42.0)- In Chrome, the pointerlock does not disengage when I let go of the mouse button

I tested it on Linux/Windows Chrome, Firefox 41/42 and haven't experienced any of the described issues. The pointer bug is a really strange one. Maybe, you have some specifics in your code? And what OS do you use?

[EDIT] Probably, your server cached some files. It is always better to disable cache (locally, or on the server) when developing apps.

I would like to be able to use the mouse pointer to click-select objects in the same scene. Pointerlock interferes with that. How do I integrate the two 'modes' smoothly? If possible I'd like to have the pointerlock only engaged when the lmb is being held down, or, if not, do this in a way that avoids pointerlock.