XBoxMouse Simulator Open Source V1.5
This program simulates a mouse using your XBox 360 Controller and allows you to quickly toggle this function ON/OFF. Please see the image below for hotkeys and controls.
This program features a solution to issues when binding the left and right trigger buttons (LT and RT). Some older games wont even recognize them as they are bound to an “axis” using DirectInput. Some games will register and bind the axis, however holding down both at the same time will actually stop input as if no buttons where pressed at all. To solve this problem this program will translate the trigger buttons into keyboard buttons Z and X. So instead of binding the LT and RT buttons directly in the older game, you bind keyboard keys Z and X.
- Simulates a mouse using your XBox 360 wireless controller for windows
- Emulates trigger buttons to keyboard keys. (LT and RT translates into keyboard keys Z and X)
- This program is written to run silently in the background.
- To change settings please right click the system tray icon.
- Very portable, all settings are saved in the ini file.
- Free to use and open source! You are free to use, modify and redistribute this program, but not to charge any money for it! If you do build upon it please link back here!
- This software was written in AutoHotkey version 1.0.48.05 download old versions here
- Bonus feature: Disable the windows button from the ini file
(Some people actually find this useful when gaming aggressively)
Toggle Mouse Simulator (“gaming mode” disables all hotkeys)
Toggle Triggers (LT/RT) “button to key” (Z/X) emulation
Toggle emulator enhancement keys. This enables the following:
Save state in common game emulatorsLoad state in common game emulators
(Currently supported emulators: snes9X, Project 64, pSX, ePSXe, Dolphin)
Toggle current monitor (Windows+P) (Win7 Only!)
Close current window (ALT+F4) You can also double tap Back.
Toggle current window focus (ALT+TAB)
Slow down mouse cursor speed. Hold down both for even slower!
Increase / decrease audio volume (Primary audio output device)
To change advanced settings right click the system tray icon and select “Edit advanced settings” to manually edit the ini file.
The ini file will be created in the same directory as the executable when you start the program for the first time.
If you accidentally mess up the settings in the ini file, please delete it and restart the program.
JoyMultiplier sets the cursor speed, use small values and decimals.
JoyThreshold sets the joysticks deadzone. Before changing this, please recalibrate your controller. If the cursor still wont stay still, slightly increase this value.
There is no installation file, simply extract the executable to a desired folder and run.
You can add this program to start automatically every time you start your computer by creating a shortcut to it in your start menu startup folder. (This will not work in Windows 8, please see below)
Download version 1.50 – (mirror 1) (mirror 2)
The source code is included in the zip archive!
You can also fork it on GitHub https://github.com/Nirklars/XBoxMouse
- In Windows 8 ALT+TAB has become system hotkeys with restricted access. In order for programs to override this they need to present a valid certificate which needs to be purchased from Microsoft. Hence ALT+TAB will not work. Sorry about this!
- Windows 8 has increased security for the startup folder. It silently blocks any programs in the startup folder which are also set to “run as administrator”.In order to launch automatically on startup you need to create a scheduled task using Windows Task Sheduler. You need to configure it to “run at log on” and also check the box to “run with highest privileges“. Please see these or these instructions on how to schedule tasks.This procedure has to be done even if logged in as an administrator with UAC disabled.
Known issues, comments
- Some AntiVirus programs report AutoHotkey scripts as false positives, please read about it in this open letter from AutoHotkey. here
- If you are unable to close the On-Screen-Keyboard this is because you are not running the program as an administrator.
- Bug testing has only been performed on Windows 7 Ultimate 64 bit and Windows XP Pro 32 bit. Please comment if you encounter any!
- I’m trying to write the code to block input while the Mouse simulator is enabled, as of yet I haven’t figured out how to do this.
- When you start the program without a controller and plug it in later, you need to press button A in order to re-detect it!
- You can’t click on the system tray using the controller, this will suspend the program. This appears to be a hardcoded feature in AutoHotkey. I’m researching if this can be circumvented somehow. If you know how to do it, please comment!
AutoHotkey – Free Mouse and Keyboard Macro Program with Hotkeys and AutoText
XInput 360 Controller API – By Lexikos
Read/write JSON parser – By polyethene
XNA Button Pack – Jeff Jenkins for the button icons
You can now invert the volume trigger button hotkeys from the ini file. Default key binding: LT decreases and RT is increases.
Finally you can quickly switch monitor output! Hold down LB+RB and press Enter to switch output to your TV (Sends the key Win+P, Please not that this does not work on windows older than 7!)
Extras bonus feature, Windowed “Fake” fullscreen. Holding down Ctrl+Alt and pressing F12 will maximize your current window and remove the borders. If you use this for games that replace input keys, it will not work. To use this you need an automated delay before applying the setting. You can do this with my other software AHKGameFrontend!
For those who have tried to modify the code you should know I have begun to cleanup the code for detecting modifier keys, the old solution was very clumsy for humans to read. It will take some time however to clean up.
Fixed a bug that caused an upward scroll when the controller shuts down for battery saving.
The mouse speed decrease multiplier now also works with the RB button! I don’t know why I didn’t include this the last time.
Mouse scrolling has been reworked. It now features a soft “nudge” when slightly moving the joystick and accelerates after a certain point. Both acceleration and the start of acceleration is configurable in the ini file! Please use small values with decimals if you are tinkering with the values.
You can now double-tap Back to simulate pressing ALT+F4. or hold down LB+Back. (Useful in programs which minimize to tray when pressing escape) The double-tap delay is configurable in the ini file. (Default value is 200 milliseconds)
The mouse speed decrease multiplier has been added to the ini file. This enables the possibility to increase mouse speed (if you like) when holding down LB by typing a decimal value smaller than 1.oo for example 0.5 will instead double the mouse speed.
Holding down LB will temporarily reduce the speed of the mouse cursor for clicking those pesky small buttons! This was something I was missing myself and really like how it got implemented! Also to reduce conflict, if you moved the cursor while holding down the normal LB command will not send the event. This to improve smoothness and annoying double outputs!
Integration in windows explorer and browsers using LB and RB will not interrupt the LB+RB for window toggling (ALT+TAB) they are now handled on the key-up event.
Audio volume control using trigger buttons when Mouse Simulator is enabled. Toggle Mouse Simulator off using (LB+RB+B) when gaming.
Integration with windows explorer (LB and RB now sends back and forward in history)
Integration with Video LAN VLC Media player. RB will now toggle play/pause. I’m not sure if this is the best key binding but I wanted to use a single button that wouldn’t disturb any other keys.
Better automatic joypad detection!
Please note that if no Joysticks are detected when starting the program, you need to right click the system tray icon and click ‘Reload’ in order to re-detect them. You can override auto-detection by editing the ini file. I do not recommend this at the moment because if no Joysticks are detected the script will loop and use unnecessary CPU power. I haven’t found a better way to circumvent this yet.
This has now been replaced by “waking up” the controller detection by pressing the first button (A) on any gamepad!
Cleaned up code.
Replaced the help/about dialog with links.
Windows XP compatability for previous update fixed! This could be improved further by blocking normal left/right input while using the hotkey. I will attempt to find a way to do this in the future.
New hotkey! LB+RB+Left/Right will switch your current program as if pressing ALT+TAB. (Bug testing only done on Windows 7 so far)
Bug fix to prevent multiple instances of MSSWCHX.EXE from stacking when using the on screen keyboard on Windows XP.