AGS produces file waste in User folder

Started by Cmdr, Sun 01/11/2020 10:22:05

Previous topic - Next topic

Cmdr

Games made with old versions of AGS put their save games where they belong: into the games folder.
In newer versions someone came up with the idea, to put them in the Windows User profile under Saved Games. It is very impractical to seperate the save games from their game for various reasons: F.e. if you store your game onto an usb drive to play on different computers, your save games won't come with you.

Thank god you still made it possible to store save games into games folder with the option "Custom Games Path".

But: The game still creates a folder with the game name into User/Saved Games, just to put a copy of the config file there. That`s an unnecessary producing of file waste into the User profile which nobody needs. It`s not using much disc space but it's just annoying to have the User profile being littered up with unnecessary folders and files.
I just don't want my games to create any folders and files outside of their own folder.

heltenjon

Quote from: Cmdr on Sun 01/11/2020 10:22:05
Games made with old versions of AGS put their save games where they belong: into the games folder.
In newer versions someone came up with the idea, to put them in the Windows User profile under Saved Games. It is very impractical to seperate the save games from their game for various reasons: F.e. if you store your game onto an usb drive to play on different computers, your save games won't come with you.

Another slight problem (or advantage) with this is that if you download new and updated versions of the game, you still have access to the old saved games. This may be a good thing, if you don't lose your progress, or a bad thing, if it causes a crash or some logical inconsistencies. I guess that depends on how much the game is changed between the builds.

Cmdr

Quote from: heltenjon on Sun 01/11/2020 10:43:14
Another slight problem (or advantage) with this is that if you download new and updated versions of the game, you still have access to the old saved games. This may be a good thing, if you don't lose your progress, or a bad thing, if it causes a crash or some logical inconsistencies. I guess that depends on how much the game is changed between the builds.

Right. In most cases the game will crash loading a save game from a different version.

Crimson Wizard

#3
The main reason why saves were moved to user documents (this happened over a decade ago btw, around new AGS 3.0 appeared) was the same as why they are stored there for most modern games: because game may be installed in a non-writeable location (either physically non-writeable, or one where user does not have write permissions). This became a general practice for software these days, and also the reason why there's this "Saved Games" folder on Windows at all (Linux have similar dedicated place for user files).
This is also the reason why user config was moved there also in later version (3.3.5, I believe). This was done by actual game developer's request, because otherwise game could not write config for some of his players when installed in Program Files.
All of this is perhaps a result of AGS users going into commercial game development, where standards are somewhat different, and situations may be more complicated.

Of course at the same time this caused annoyance among other people. Custom save path was added much later, primarily for Steam releases iirc.

But this is still an issue that is brought every now and then, and it was already reported few times both on forums, and posted our issue tracker.
This was in my personal plans to work on this recently, but other things got in a way.

I am still wondering what would be the best way to support both methods and let users switch between them more easily, and I need to think this over very carefully.
The most trivial solution would be to use a simple switch in game config (this was originally planned), but idk if it will be very convenient on platforms where we do not have a standard setup program, as a person would have to do set it manually in file for each downloaded game. There are other concerns about writing to default config file too. I had some thoughts about alternative, but they are not shaped enough yet.

Cmdr

Thank you for your detailed reply.
I understand, that different developers have different opinions about that. Especially commercial developers have different requirements for their game than a little fangame maker like me.
That's why I'm happy with your solution to chosse a Custom same Path and set a default value as the developer (as it is).

But is their a reason why the config file is still stored in the user profile when the game directory is choosen as the Custom same Path? Why not store the config file always at the choosen save path in the configuration? Or give the developers the option to choose where they want to have the config file.

Crimson Wizard

#5
Quote from: Cmdr on Mon 02/11/2020 10:06:13
But is their a reason why the config file is still stored in the user profile when the game directory is choosen as the Custom same Path? Why not store the config file always at the choosen save path in the configuration? Or give the developers the option to choose where they want to have the config file.

To be honest, I don't remember exact reason why I did not do that immediately, maybe I did not think about it at that time, or maybe a new release was being prepared and I did not want to fiddle with important logic.

There was also this stupid problem of how to have this option. The custom save path cannot simply define user config location too, because the save path is written to user config :) (because we let players choose their own).
So the user config location would have to be defined only by default config (and not allowed to be changed by setup program, but only either defined at compilation time or fixed by manually editing config file in game folder), or there has to be some other alternative way of hinting engine what to do.
One idea was to let user config have different name. E.g. replace acsetup.cfg with default.cfg and user.cfg. Then, if user.cfg is present in the game folder, then engine would use it, and if it's not present, then it will use the determined user profile path.
Maybe there are other alternatives... I must discuss this with other developers and AGS users too, to make sure the solution covers all necessary cases.

Anyway, this definitely has to be done in one of the next releases, if not just the next one (we have some version planning issues at the moment, which we need to resolve first).

Cmdr

Quote from: Crimson Wizard on Mon 02/11/2020 14:32:05
Anyway, this definitely has to be done in one of the next releases, if not just the next one (we have some version planning issues at the moment, which we need to resolve first).

This would be great! Thank you for considering it.

SMF spam blocked by CleanTalk