You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently libGDX does not follow best practices to store local files (those accessed via Gdx.files.local) on the desktop operating systems. Currently, it seems to just use the working directory. I would like to purpose changing libGDX to use the correct directory for the operating system. It would use the AppData folder on Windows, the correct folder for Mac, and for Linux we can probably keep the same behavior. I would hope that most developers did not write their code with the assumption that internal files and local files are both in the same path since this change would likely break any code that makes that assumption. To get around that, we could have it so that by default libGDX uses the current behavior but can optionally be switched to follow the best practices for the operating system. Perhaps a function called setStorage can be added to the ApplicationConfiguration class? This function would take a boolean as a parameter and when set to true, it would use the AppData folder instead of what it currently does.
I would be willing to take the time to implement this code but I only have a Windows machine and a Ubuntu machine. I would need someone with a Mac to test.
Is this something that I should pursue or that the greater community is interested in?
The text was updated successfully, but these errors were encountered:
I think many games actually would prefer using the current working directory for local files, since AppData is a hidden folder by default on Windows. Many users who might want to access a locally-saved backup or some other locally-written file could lack the knowledge or permissions to access their AppData folder. I think if there is a change, there needs to be a way to configure the location, as with the suggested setStorage. There might be benefits to having presets for the appropriate AppData subfolder (which might already be used by Preferences, but I'm not sure), the current working directory, and maybe a temp folder. I think the default should remain as-is, but by having the configurable setStorage, games can save files hopefully more how they want to.
Good evening,
Currently libGDX does not follow best practices to store local files (those accessed via
Gdx.files.local
) on the desktop operating systems. Currently, it seems to just use the working directory. I would like to purpose changing libGDX to use the correct directory for the operating system. It would use the AppData folder on Windows, the correct folder for Mac, and for Linux we can probably keep the same behavior. I would hope that most developers did not write their code with the assumption that internal files and local files are both in the same path since this change would likely break any code that makes that assumption. To get around that, we could have it so that by default libGDX uses the current behavior but can optionally be switched to follow the best practices for the operating system. Perhaps a function calledsetStorage
can be added to theApplicationConfiguration
class? This function would take a boolean as a parameter and when set to true, it would use the AppData folder instead of what it currently does.I would be willing to take the time to implement this code but I only have a Windows machine and a Ubuntu machine. I would need someone with a Mac to test.
Is this something that I should pursue or that the greater community is interested in?
The text was updated successfully, but these errors were encountered: