Closed garbear closed 7 years ago
that ends up closing RetroArch though. I guess the shutdown env is not implemented in your frontend.
how does a game signal that it should be closed? I thought that was what the shutdown env command was for?
Is there a difference between "close emulator" and "shutdown retroarch" commands? Is there a way to just close the emulator and reactivate core select? RETRO_ENVIRONMENT_SHUTDOWN Requests the frontend to shutdown. Should only be used if game has a specific way to shutdown the game from a menu item or similar.
@garbear it's supposed to shutdown the whole thing. I guess in retroplayer it doesn't honour it but RA does it (that's why we disabled that)
No there is no way to do just close the core from within the core.
That entire env is a confusing mess. I've seen someone try to use it as "internal error, can't continue, can't even return from this function, just kill me". (Don't know if it was fixed.)
I think disabling the exit command on the top level prompt would be better,it would still work if you started a new prompt from a program or the CMD line.
I was mistaken, the shutdown env is to power off the system, not close the game or RetroArch. According to the doc:
* Requests the frontend to shutdown.
* Should only be used if game has a specific
* way to shutdown the game from a menu item or similar.
Should this env command be removed? It doesn't make sense to shutdown Lakka on the RPi, and on Kodi there are different modes of shutdown (Exit, Shutdown, Reboot, Shutdown timer, etc), so it doesn't make sense to honor this env there either.
Maybe we should add an env RETRO_ENVIRONMENT_UNLOAD_GAME
for those cores with "a specific way to shutdown the game from a menu item or similar"? E.g. these two:
This would be better implemented as a "Your emulated computer has powered off, you can now close RetroArch safely." message instead of killing RetroArch or just locking up.
If there is a core exit method that wont kill RetroArch I dont know of please post it and I will reopen this and implement it.
When I typed "exit", dosbox went into an infinite loop instead of exiting to Kodi