-
Notifications
You must be signed in to change notification settings - Fork 14
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
Allow to use core name as save filename #17
base: master
Are you sure you want to change the base?
Conversation
Add the 'save_filename' variable with the default 'game' value not changing the current behavior and the 'core' value using a static name based on the core's filename for every save file. This allows frontends creating one save directory per game to let the users rename their game file without loosing their save.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems overly complicated for no reason.
The current behavior is most likely because it's an unmantained, hardly used core.
I think a better approach would be to follow what other cores do (use libretro srm interface or use the save dir with the game name)
I thought about allowing access to the save RAM instead of writting save files, but as there are multiple save RAMs here and Libretro don't have RO and WO save RAM accessors like for serialization, but only a RW one you can't serialize/deserialize the save RAM. Instead you would have to put all the save RAMs and their metadata in a contiguous buffer within the emu… It's doable with a LOT more refactoring and it's probably not worth the pain. This changes is simple and doesn't break the default behavior (hence the current users don't loose their save files) while solving the problem of game file renaming for frontends having one save directory per game and identifying the games with something else than the filename. |
@fr500 As you said the core is unmaintained and hardly used, is there one you would recommend instead? :) |
mGBA all the way |
We should implement save files through the proper libretro get_memory/set_memory callback functions. It should be discouraged to do save files any other way through a libretro core if we can prevent it. |
the core is able to support mednafen save method, as well as using the libretro api. so, this PR might not be relevant anymore. |
Add the 'save_filename' variable with the default 'game' value not
changing the current behavior and the 'core' value using a static name
based on the core's filename for every save file.
This allows frontends creating one save directory per game to let the
users rename their game file without loosing their save.