Jump to content

Pointer Lock API but also still use the mouse to click on stuff?


madmuffin
 Share

Recommended Posts

I'm referring to the https://developer.mozilla.org/en-US/docs/Web/API/Pointer_Lock_API to keep the mouse from leaving your game window, however we're having a problem that after you engage the lock, we can't find a method to keep using the mouse functionality to click on things within the box. The mouse is locked to some arbitrary spot, and while we can map its movements to move a fake sprite mouse around, we can't click from that fake sprite mouse.

Does anyone know of any examples that accomplish this?

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...