mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-04-23 21:46:15 -04:00
Allow loading saves from newer versions
This commit is contained in:
parent
0cb4945e7d
commit
11c797bc59
3 changed files with 19 additions and 9 deletions
13
src/game.ts
13
src/game.ts
|
@ -705,12 +705,13 @@ async function openSettingsMenu() {
|
|||
} = JSON.parse(content);
|
||||
if (fileType !== "B71-save-file")
|
||||
throw new Error("Not a B71 save file");
|
||||
if (fileVersion > appVersion)
|
||||
throw new Error(
|
||||
"Please update your app first, this file is for version " +
|
||||
fileVersion +
|
||||
" or newer.",
|
||||
);
|
||||
// Actually, loading a save file to an older version is pretty useful
|
||||
// if (fileVersion > appVersion)
|
||||
// throw new Error(
|
||||
// "Please update your app first, this file is for version " +
|
||||
// fileVersion +
|
||||
// " or newer.",
|
||||
// );
|
||||
|
||||
if (
|
||||
key !==
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue