Simulate mouse inputs in 3d games
Project description
KiwiMouse
Simulate mouse movement in 3d games using this package.
Dependencies
Windows has no dependencies. The Win32 extensions do not need to be installed.
Example Usage
Mouse Control
The x, y coordinates used by kiwimouse are relative to the current mouse position. The x coordinates increase going to the right (just as in mathematics) but the y coordinates increase going down (the opposite of mathematics). Keep in mind that in 3d games mouse movement is not correlated 1:1 to the monitor pixel position.
Main focus of this package was to give the ability to control the mouse in the game window. All mouse events are sent to the active window.
import kiwimouse
kiwimouse.click(button='right') # click right mouse button
kiwimouse.move(0, -500) # move mouse up 500 px
kiwimouse.click(button='left') # click left mouse button
kiwimouse.move(0, 500) # move mouse down 500 px
Dy default after each operation time.sleep(.1)
is executed. You can change it by altering kiwimouse.PAUSE
value
Documentation
The mouse event
windows documentation could be found at link
Testing
To run the supplied tests: first setup a virtualenv. Then you can pip install this project in an editable state by doing pip install -e .
. This allows any edits you make to these project files to be reflected when you run the tests. Run the test file with python3 tests
.
I have been testing with ULTRAKILL to confirm that these inputs work with DirectX games.
Features Implemented
- Fail Safe Check (as in pyautogui)
- move(x,y) / moveRel(x,y)
- click()
Features NOT Implemented
- move to specific pixel on screen
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file kiwimouse-1.0.0.tar.gz
.
File metadata
- Download URL: kiwimouse-1.0.0.tar.gz
- Upload date:
- Size: 16.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.12.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a537a9f53ffd0a741dc09103a1fbdf9d9c487baf68ae89b6b7a62582bc89a306 |
|
MD5 | 16c504167ea5a54e2f5abf66a006cded |
|
BLAKE2b-256 | b92f542b5d25dbd3667d1f8c03a978f405dc73b52702fb80c2a92a69f9cce848 |
File details
Details for the file kiwimouse-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: kiwimouse-1.0.0-py3-none-any.whl
- Upload date:
- Size: 15.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.12.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7075934a8cce3d9302462ec3555cb084debdf44d432ad455ae02a2178f31d602 |
|
MD5 | 6ef46720a8a09bce2bbdbe33cf9401a9 |
|
BLAKE2b-256 | e0f9344f897f688d5b641d05e9c5b18568234528444acc9c9ab10993b2a19f19 |