Skip to content

Provides additional features like smoothing to pointer-lock.

Notifications You must be signed in to change notification settings

standayweb/pointer-lock-plus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Pointer Lock Plus

Provides additional features like sensitivity to pointer-lock.

Code Example

import lock from 'pointer-lock-plus';

const pointer = lock({
  element: canvas,
  sensitivity: 0.0015,
  onData(dx, dy) {
    console.log(dx);
    console.log(dy);
  },
});

Installation

npm install pointer-lock-plus

API Reference

It has the same hooks as pointer-lock events, prefixed with on (onData, onClose, etc) and the the same callbacks are also available.

Contributors

Contributions are welcome and suggestions on more stuff this library should offer.

About

Provides additional features like smoothing to pointer-lock.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages