All Projects → vincentbavitz → bezmouse

vincentbavitz / bezmouse

Licence: other
Simulate human mouse movements with xdotool

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to bezmouse

MouseInjectDetection
Simple method of checking whether or not mouse movement or buttons (<windows 10) are injected
Stars: ✭ 29 (-73.64%)
Mutual labels:  mouse, mouse-movement
Pycraft
Pycraft is the OpenGL, open world, video game made entirely with Python. This project is a game to shed some light on OpenGL programming in Python as it is a seldom touched area of Python's vast amount of uses. Feel free to give this project a run, and message us if you have any feedback!
Stars: ✭ 39 (-64.55%)
Mutual labels:  pyautogui
gear-vr-controller-linux
Gear VR Controller Linux WebBrowser mouse
Stars: ✭ 37 (-66.36%)
Mutual labels:  uinput
Pyautogui-module-using-audio
📌 This repo is all about how we implemented pyttsx3,speech_recognition,colored all three modules with pyautogui module.
Stars: ✭ 25 (-77.27%)
Mutual labels:  pyautogui
kbct
Keyboard keycode mapping utility for Linux supporting layered configuration
Stars: ✭ 209 (+90%)
Mutual labels:  uinput
btnx-config
btnx-config is a configuration tool for btnx (Button Extension). It allows the user to send keyboard combinations or execute commands with mouse buttons. btnx-config provides mouse and button detection, and an easy way to configure btnx's behavior. See https://github.com/cdobrich/btnx/ for btnx.
Stars: ✭ 47 (-57.27%)
Mutual labels:  mouse
Enigo
Cross platform input simulation in Rust
Stars: ✭ 254 (+130.91%)
Mutual labels:  mouse
vmwmouse
VMware mouse driver for Windows 3.1
Stars: ✭ 315 (+186.36%)
Mutual labels:  mouse
python web scraping
Web scraping using python, requests and selenium
Stars: ✭ 40 (-63.64%)
Mutual labels:  pyautogui
1000hz
Overclock your old mouse and increase its polling rate
Stars: ✭ 45 (-59.09%)
Mutual labels:  mouse
MouseWheel
adjust the mouse scroll speed ubuntu
Stars: ✭ 24 (-78.18%)
Mutual labels:  mouse
gta-samp-mouse-only
Play GTA San Andreas Multiplayer with mouse only and no keyboard
Stars: ✭ 22 (-80%)
Mutual labels:  mouse
SwiftUI-bez
Utilities for working with bezier curves in SwiftUI
Stars: ✭ 80 (-27.27%)
Mutual labels:  bezier-curves
rapp
Cross-platform entry point library
Stars: ✭ 57 (-48.18%)
Mutual labels:  mouse
bezier-editor
A tool base on HTML5 canvas to create bezier curve like photoshop and then it can be exported as JavaScript code to create an animation path for an HTML element.
Stars: ✭ 21 (-80.91%)
Mutual labels:  bezier-curves
InputSimulatorStandard
Input Simulator Standard
Stars: ✭ 54 (-50.91%)
Mutual labels:  mouse
phaser3-plugin-pathbuilder
Draw and edit Lines, Bezier Curves, Splines at runtime, explore your scene and export your paths to Phaser
Stars: ✭ 67 (-39.09%)
Mutual labels:  bezier-curves
mx3000control
Perixx MX-3000 mouse unofficial configuration tool for Linux
Stars: ✭ 20 (-81.82%)
Mutual labels:  mouse
Kursor
Cursor style with javascript and css
Stars: ✭ 140 (+27.27%)
Mutual labels:  mouse
keyboard mouse emulate on raspberry
Bluetooth Keyboard Mouse Emulator on Raspberry Pi
Stars: ✭ 230 (+109.09%)
Mutual labels:  mouse

BezMouse

BezMouse is a lightweight tool written in Python to simulate human-like mouse movements with Bézier curves. Some applications might include:

  • aimbots (prevent bans)
  • MMORPG bots (avoid macro detection)
  • controlled macros

BezMouse was originally written for a RuneScape color bot and has never triggered macro detection in over 400 hours of continuous use.

Noteworthy Functions

move_to_img - this function takes the name of an input image (excluding file extension) and moves the mouse to a random pixel on that image if it is found on the screen. Commands for xdotool are saved to a temporary bash file in the ramdisk ./tmp called 'mouse.sh'. It is then executed as a bash script to give best performance. Note: This function is very slow because it must identify the image across your screen. It is highly recommended to find the coordinates of the image in a separate thread and feed this into the move() function.

connected_bez - connects all the (x, y) coordinates in a list of coordinates with a string of interconnected Bézier curves. A parameter deviation is required which controls how straight the lines drawn by the cursor are. Zero deviation gives straight lines. Accuracy is a percentage of the displacement of the mouse from point A to B, which is given as maximum Bézier control point deviation. Naturally, deviation of 10 (10%) gives maximum control point deviation of 10% of magnitude of displacement of mouse from point A to B, and a minimum of 5% (deviation / 2). Here is an example of connected_bez as a trace of the mouse as it passes 26 points in order, where deviation is set to 30.

connected_bez_example

move Each of the move_* functions are abstractions from the move function which handles the math of the Bézier curves such to produce realistic overshoots as well as variable speed and momentum. The following graphic was made using the draw = True argument and demonstrates the overshoot and variable speed. overshoot_example

Dependencies

Development

Find something wrong with my code? See room for improvement? Please let me know!

Regarding Performance

I am looking into injecting mouse events directly into a uinput virtual mouse. This has the benefits of:

  • minimising latency
  • giving OS-level control over mouse acceleration
  • generating perfectly smooth, coordinate independent movements
  • eliminating heavy dependencies

I will implement this feature if I can find an equivalent to uinput for Windows.

Todos

  • Make available for Windows / OSX
  • Improve performance
  • Remove dependency PyAutoGui in favour of just xdotool.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].