Save compatibility handling (#7255)

* Add serialization version to GameInfo

* Add handling of incompatible saves due to a dfiferent save version

* Fix compilation?

* Fix ios compilation

* Refactor: Make it clearer that GameInfo serialization version is only supposed to be incremented when it's guaranteed to cause issues & rename to compatibility version

* Update initial version

* Update initial version

* Fix merge mistake
This commit is contained in:
Timo T
2022-07-01 08:34:41 +02:00
committed by GitHub
parent 08cede4f5a
commit 57ed61af41
70 changed files with 545 additions and 368 deletions

View File

@ -331,7 +331,6 @@ National ability =
Uniques =
Promotions =
Load copied data =
Could not load game from clipboard! =
Reset to defaults =
Are you sure you want to reset all game options to defaults? =
Start game! =
@ -630,7 +629,10 @@ Saved game name =
[player] - [turns] turns =
Copy to clipboard =
Copy saved game to clipboard =
Could not load game =
Could not load game! =
Could not load game from clipboard! =
Could not load game from custom location! =
The save was created with an incompatible version of Unciv: [version]. Please update Unciv to at least [version] and try again. =
Load [saveFileName] =
Are you sure you want to delete this save? =
Delete save =
@ -647,7 +649,6 @@ If you could copy your game data ("Copy saved game to clipboard" - =
I could maybe help you figure out what went wrong, since this isn't supposed to happen! =
Missing mods: [mods] =
Load from custom location =
Could not load game from custom location! =
Save to custom location =
Could not save game to custom location! =
Download missing mods =

View File

@ -50,7 +50,6 @@ open class AndroidLauncher : AndroidApplication() {
platformSpecificHelper.toggleDisplayCutout(settings.androidCutout)
val androidParameters = UncivGameParameters(
version = BuildConfig.VERSION_NAME,
crashReportSysInfo = CrashReportSysInfoAndroid,
fontImplementation = NativeFontAndroid((Fonts.ORIGINAL_FONT_SIZE * settings.fontSizeMultiplier).toInt(), fontFamily),
customFileLocationHelper = customFileLocationHelper,