-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Locking and unlocking by ways other than input action id. #3
Comments
In this extension (although it's more just an example implementation rather than an extension anymore) I was assuming the behaviour of large PC games, where the game launches and you give the game cursor control with a mouse click. That's the industrial standard in PC games, in my opinion. As it is, I agree that this behaviour should be made customisable. |
I realised that games really do capture the cursor always by providing their own virtual cursor. Then, if the cursor is even virtual, usually, when you start a PC game, the cursor is captured immediately and automatically, without an additional click. To do it still need some sort of command, other than a click. |
Yeah, but you can lock mouse without user iteraction only on PC/Mac. So just call P.S. I will add a flag like |
Wait a minute, it's possible to do with the inbuilt api at the moment? Omg, where have I been all this time... 😂 Thanks for the discovery! Now I'll have to figure out the best way to use it all for the operator's demo and readme 🤔 |
Yes, there is a huge statement on the top of Pointer Lock's README:
|
From the real world, before locking the cursor, the game shows the game menu and other stages where standard behaviour is required. And then, when the player presses the "Start Game" button, the game level loads and the cursor is locked. Conversely, when the player, for example, opens a chest in the game world, the inventory window opens and the cursor is unlocked.
In this case it would be more convenient to have some kind of interface for locking, a module method or message handling. As it is not clear why locking should be related to mouse click.
Maybe I don't fully understand the idea of a virtual cursor and this is the solution?
The text was updated successfully, but these errors were encountered: