Shortcut keys to specific games
-
Hi, is there a way to assign a keyboard combination of keys to launch a specific game? For example, Ctrl+Shift+Alt+S to launch Space Invaders, or Ctrl+Shift+Alt+G for Ghost n Goblins.
I have an Adafruit Macropad that can simulate key presses. I use it on windows for the odd thing, but I started wondering if I could use it to launch individual games in retropie, the first step being assigning shortcut keys to games.
Thanks,
Col. -
@coldunn said in Shortcut keys to specific games:
Hi, is there a way to assign a keyboard combination of keys to launch a specific game? For example, Ctrl+Shift+Alt+S to launch Space Invaders, or Ctrl+Shift+Alt+G for Ghost n Goblins.
I have an Adafruit Macropad that can simulate key presses. I use it on windows for the odd thing, but I started wondering if I could use it to launch individual games in retropie, the first step being assigning shortcut keys to games.
Thanks,
Col.Hello,
RetroPie itself doesn't directly support launching games with keyboard shortcuts. However, there are a couple of workarounds you can explore to achieve a similar outcome with your Adafruit Macropad:
- AutoHotkey Script (For Windows PCs only):
This method involves creating a script using AutoHotkey (a free program) on a separate Windows PC. This script would take your desired keyboard combination and translate it into commands that launch the specific RetroPie game through network communication.
Here's a breakdown:
On Windows PC:
Install AutoHotkey (https://www.autohotkey.com/).
Create a script that captures your desired keyboard shortcut (e.g., Ctrl+Shift+Alt+S).
Within the script, use commands like SendInput to trigger key presses that would navigate RetroPie's menus and launch the game (requires some knowledge of RetroPie's menu navigation).
Use a program like "PuTTY" or built-in SSH tools to connect to your RetroPie and run the commands sent by the AutoHotkey script.
2. RetroArch Hotkeys (For Launching within Emulators):This method focuses on configuring hotkeys within RetroArch, the emulator core used by many RetroPie games. It allows launching specific actions within the emulator itself, not directly from RetroPie's main menu.
Here's what you can do:
On RetroPie:
Access the RetroArch menu within the specific game emulator (usually by pressing a hotkey combination like "Select" + "Start").
Navigate to "Settings" -> "Input" -> "Hotkeys".
Configure a hotkey combination for an unused function like "Save State" or "Load State".
When you launch the game, use your Macropad to trigger the configured hotkey, which would then launch a pre-programmed "Save State" command that could be used to exit the emulator and return to RetroPie's main menu.
Important Note:Both methods require some technical knowledge and configuration. Setting up AutoHotkey scripts and RetroArch hotkeys might take some tinkering.
Alternative Approach:While not using keyboard shortcuts, you could consider using a program like "Launcher Manager" in RetroPie. It allows you to create custom game lists with custom icons for easier access to specific games within the RetroPie interface. This approach might be a simpler option if keyboard shortcuts aren't a must.
-
@Dennisleon Hello ChatGPT. Obviously no solution given to the poster's question, but way to dance around the issue to make it legit.
@coldunn there's no configuration/ability in EmulationStation to assign keyboard shortcuts to launching a game. You can try to do a 'macro' type of action sequence and combine it with the scripting support in EmulationStation to read where exactly you're positioned.
Something like:
- press B to 'got back', a few times so you make sure that you're in the game list
- press left then read with the scripting support which system you're on. Once you're on the right system, press 'A' to enter (you can use Favorites to simplify this and to be able to change the games)
- press 'A' to enter the system
- press 'Down' for X times to get to the X game in the list, optionally read the game name via the event's script.
- launch the desired game by pressing 'A'.
It's very cumbersome and you'll see the EmulationStation UI doing the actions corresponding to the button presses while they're executed.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.