libretro / libretro-2048

Port of 2048 puzzle game to the libretro API. http://gabrielecirulli.github.io/2048/
The Unlicense
17 stars 30 forks source link

Use RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY to work around problems wi… #22

Closed orbea closed 7 years ago

orbea commented 7 years ago

…th the savedir.

Since 2048 doesn't have any content it has problems with the RetroArch save directory. This is especially apparent when cores are installed to read only directories through a distro's package management. 2048 will either then try to save to a read only directory which won't work or the save will end up in the wrong place if used with Sort Saves In Folders. For example I found in my 2048.srm in the GLupeN64 save directory.

So I looked at Craft which also does not have any content and found it uses RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY instead. So while this may not be an ideal solution, it works much better for now and will be trivial to change back if and when the save directory behavior is improved.

Please also see issue https://github.com/libretro/libretro-2048/issues/4.

Alcaro commented 7 years ago

Working around front bugs in the core? That way likes spaghetticode and cores that don't work in other fronts. We may not get there this fast, but we get closer, and I don't like that idea.

orbea commented 7 years ago

Fair enough, this can be closed then and a better solution can be found later. Do you also have a problem with cores like Craft using the system directory?

I've made an issue report for RA. https://github.com/libretro/RetroArch/issues/4473