Skip to content
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

Backup isn't working as expected: WeiDU is backing up the overwritten version instead of the earlier version. #246

Open
the-overdriven opened this issue Oct 20, 2024 · 2 comments

Comments

@the-overdriven
Copy link

Can someone confirm if the backup actually saves the previous version of a file before it's overwritten? I have a case when WeiDU did create a backup, but the backed up file is identical as the overwritten version. It goes without saying, it should create the backup before the overwrite happens, not after.

The mod that caused the overwrite: Nostalgia Pack
The overwritten file: all quick saves.
Entry in WeiDU.log: ~NOSTALGIAPACK/NOSTALGIAPACK.TP2~ #0 #21 // Restore BG1 Character Sprites -> Everything including saved games: 1.1

The backed up .sav file is different, but .gam is the same:
baldur.gam in weidu_external\backup\nostalgiapack\21\: 112 KB (115.340 bytes)
baldur.gam in Documents\Baldur's Gate - Enhanced Edition\save\000000001-Quick-Save\: 112 KB (115.340 bytes)
Since the overwrite changed the baldur.gam file, I'd expect the backed up baldur.gam in weidu_external\backup\nostalgiapack\21\ to be different.

Both files (the new version and the supposed old version) being identical make me believe that the backup isn't working as expected.

@FredrikLindgren
Copy link
Member

The mod does not change the size of the file, so whether it's the same or not is not something you can determine by the file's size.
The mod also edits saved games with backup and in the other issue you opened you write that your saved progress is gone after re-installing. This is because the backup is restored when the mod is uninstalled (which is the first step in a re-installation), which reverts your saved game to the state it was in when you installed the mod. The mod's changes are then re-installed, but any game-progess you'd made in the meantime is gone. Save-game editing cannot safely be with backup.

If there is still an issue here, I'll take a further look.

@the-overdriven
Copy link
Author

This is because the backup is restored when the mod is uninstalled (which is the first step in a re-installation), which reverts your saved game to the state it was in when you installed the mod.

Thanks for explaining. The thing is, I don't recall having a backup in weidu_external\backup\nostalgiapack\21\, or in weidu_external\backup\nostalgiapack\*.
This file's C..Users.me.Documents.Baldur's Gate - Enhanced Edition.save.000000001-Quick-Save.baldur.sav timestamps suggest it was created the moment reinstallation happened, not earlier (all dates including creation date point to yesterday). There are no other backups either. That's why I find it difficult to believe the theory that the uninstallation step restored an old save from WeiDU's backup, although it does provide a possible explanation.

The folder itself weidu_external\backup\nostalgiapack\21\ was in fact created one week ago, but all the files inside have creation date from yesterday. There is no sign of any old save backups, assuming they ever existed. Could it be that during reinstallation WeiDU backuper removed all the old files inside weidu_external\backup\nostalgiapack\21 and created new ones, rather than modifying them?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants