A set of classes to make it easier and simpler to work with input (Mouse/Keyboard) in your games.
The full documentation can be found here.
Add it to your project via:
npm i --save evidently-input
The simplest way to use this library is as follows:
- Create a new instance of
documentto it, to register the necessary listeners.
- At the end of every frame call
update(), it must be done after you've done using the input methods.
- Where needed call the appropriate methods (eg.
An example code:
const mouseInput = ;const keyboardInput = ;// Registers necessary event listeners on the documentmouseInput;keyboardInput;;
This project is licensed under the MIT License - see the LICENSE.md file for details