Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: Allow arcade/Mame 2003+ to quit with menu button #1162

Open
schmurtzm opened this issue Sep 25, 2023 · 3 comments
Open

FIX: Allow arcade/Mame 2003+ to quit with menu button #1162

schmurtzm opened this issue Sep 25, 2023 · 3 comments
Assignees
Milestone

Comments

@schmurtzm
Copy link
Member

schmurtzm commented Sep 25, 2023

It's not possible to exit arcade games by simply pressing menu button.

Few time ago I've made this video : https://www.youtube.com/watch?v=Ode06KGi3QQ to explain to users the specialties of this platform. You can see it the first time you run an arcade game in Onion (it's also available in the video player).

The problem comes from Retroarch : it doesn't react as it should to the linux "kill" (sigterm) command. Normally the kill command should exit Retroarch properly but for many arcade games it just not work : Retroarch is not exited.

So I have created some issues to Retroarch repo :
For Retroarch : libretro/RetroArch#15717
And this one for Mame2003+ : libretro/mame2003-plus-libretro#1623

The interesting fact is that configuring a hotkey to exit Retroarch works properly.... So the workaround is to drive Retroarch from the Network command line API : this QUIT command exits arcade properly and it makes the save state. So we have a workaround 🎉

Many other network commands are not documented and it will be interesting to investigate on the possibilities that it gives.

Example to drive retroarch from windows : sfk199.exe udpsend 192.168.0.203 55355 QUIT
(You'll find sfk199 here).

It will require some little modifications in Onion to implement this : We justs need to have HAVE_COMMAND = 1 in our RA build and network_cmd_enable = "true" in the retroarch.cfg and then we need to update keymon to manage this new API instead of kill/sigterm.

@schmurtzm schmurtzm added this to the v4.3 milestone Sep 25, 2023
@schmurtzm schmurtzm changed the title allow arcade/Mame 2003+ to quit with menu button Allow arcade/Mame 2003+ to quit with menu button Sep 25, 2023
@schmurtzm schmurtzm changed the title Allow arcade/Mame 2003+ to quit with menu button FIX: Allow arcade/Mame 2003+ to quit with menu button Sep 25, 2023
@mmc41
Copy link

mmc41 commented Oct 21, 2023

Does this also fix that shutdown button is ignored as well during arcade games ?

@schmurtzm schmurtzm modified the milestone: v4.3 Oct 21, 2023
@schmurtzm
Copy link
Member Author

Does this also fix that shutdown button is ignored as well during arcade games ?

it should yes ;)

@seanstardev
Copy link

I love the OP's idea and description for a solution here. Great out of the box thinking :)

I've noticed that some arcade games still don't exit when 'Menu' button is pressed. Has anyone else observed this, or is it possible I've mucked up my settings? Happy to provide specific problem games if that helps :)

@schmurtzm schmurtzm modified the milestones: v4.3, v4.4 Feb 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 📋 Backlog / To do
Development

No branches or pull requests

5 participants
@mmc41 @seanstardev @schmurtzm @Aemiii91 and others