https://github.com/arevi/wind-mouse
A JavaScript library for generating human-like mouse movement data points.
https://github.com/arevi/wind-mouse
human javascript mouse movement nodejs typescript windmouse
Last synced: 11 months ago
JSON representation
A JavaScript library for generating human-like mouse movement data points.
- Host: GitHub
- URL: https://github.com/arevi/wind-mouse
- Owner: arevi
- License: mit
- Created: 2020-09-20T00:17:43.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T14:39:46.000Z (over 3 years ago)
- Last Synced: 2025-07-22T22:05:15.340Z (11 months ago)
- Topics: human, javascript, mouse, movement, nodejs, typescript, windmouse
- Language: TypeScript
- Homepage:
- Size: 826 KB
- Stars: 69
- Watchers: 1
- Forks: 5
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## WindMouse
WindMouse is a lightweight, and highly configurable, library for generating human-like mouse movement. The data points are then returned in a x,y point array for further usage.
### Installation
```
npm install windmouse
```
### Usage
```
const WindMouse = require("windmouse");
// Initialize WindMouse class
const windMouse = new WindMouse(Math.floor(Math.random() * 10));
// MouseSettings
let settings = {
startX: Math.ceil(Math.random() * 1920),
startY: Math.ceil(Math.random() * 1080),
endX: Math.ceil(Math.random() * 1920),
endY: Math.ceil(Math.random() * 1080),
gravity: Math.ceil(Math.random() * 10),
wind: Math.ceil(Math.random() * 10),
minWait: 2,
maxWait: Math.ceil(Math.random() * 5),
maxStep: Math.ceil(Math.random() * 3),
targetArea: Math.ceil(Math.random() * 10),
};
// Print points
async function logPoints() {
let points = await windMouse.GeneratePoints(settings);
console.log(points);
}
logPoints();
```
### WindMouse Visualizer
https://github.com/arevi/mouse-data-visualizer
### Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
### License
https://opensource.org/licenses/MIT
### Credits
The original WindMouse library was created by https://github.com/BenLand100 for Java. This is a port of said library enabling for usage with JavaScript/TypeScript.