When using the Mouse Pointer Lock extension (say, for a first person game) it seems like it has the built in behavior to prioritize Esc key to unlock the cursor
The issue is ,I want to use Esc key to open my own custom Pause menu, but I end up having to press it multiple times, because the first press only gets recognized and overwritten by this Mouse Pointer Lock extension.
How can I at least prioritize the Esc key to open my menu upon pressing?
I know the code I have works fine, and the problem is just the Esc key, because if I change the key to something else, it works perfectly.
Theres just a conflict with the Esc key and this extension.