diff --git a/README.md b/README.md index c1bdada..ba7999c 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,7 @@ Legend: ✅ Confirmed working, ❔ Unconfirmed, - Not available in the store | Railway Empire 2 | ❔ | ❔ | | Remnant 2 | ✅ | ❔ | | Remnant: From the Ashes | ❔ | ❔ | +| Scorn | ✅ | - | | Starfield | ✅ | - | | State of Decay 2 | ❔ | ❔ | | Totally Accurate Battle Simulator | ✅ | - | @@ -77,4 +78,4 @@ Run `main.py` with Python 3.10+. The script produces ZIP files for each of the s ## Thanks Thanks to [@snoozbuster](https://github.com/snoozbuster) for figuring out the container format at https://github.com/goatfungus/NMSSaveEditor/issues/306. -Also thanks to everyone that has [contributed](https://github.com/Z1ni/XGP-save-extractor/graphs/contributors) by adding support for new games. \ No newline at end of file +Also thanks to everyone that has [contributed](https://github.com/Z1ni/XGP-save-extractor/graphs/contributors) by adding support for new games. diff --git a/games.json b/games.json index 3164ca5..3a4f728 100644 --- a/games.json +++ b/games.json @@ -58,6 +58,14 @@ "suffix": ".sav" } }, + { + "name": "Scorn", + "package": "KeplerInteractive.1439274AB3A46_ymj30pw7xe604", + "handler": "1c1f", + "handler_args": { + "is_scorn": true + } + }, { "name": "Yakuza 0", "package": "SEGAofAmericaInc.Yakuza0PC_s751p9cej88mt", diff --git a/main.py b/main.py index 9bf9961..62408f8 100644 --- a/main.py +++ b/main.py @@ -263,11 +263,20 @@ def get_save_paths( if handler_name == "1c1f": # "1 container, 1 file" (1c1f). Each container contains only one file which name will be the name of the container. file_suffix = handler_args.get("suffix") + is_scorn = handler_args.get("is_scorn") for container in containers: fname = container["name"] if file_suffix is not None: # Add a suffix to the file name if configured fname += file_suffix + if is_scorn: + # Scorn has extensions at the end, but without the dot separator, so re-add them with the dot + if fname.endswith('sav'): + fname = fname.removesuffix('sav') + '.sav' + elif fname.endswith('info'): + fname = fname.removesuffix('info') + '.info' + elif fname.endswith('dat'): + fname = fname.removesuffix('dat') + '.dat' fpath = container["files"][0]["path"] save_meta.append((fname, fpath))