SCI32: Match 4-language MGDX extra save game data
This commit is contained in:
parent
bfa6ad5155
commit
dbdbb9b5b3
1 changed files with 10 additions and 1 deletions
|
@ -367,7 +367,16 @@ reg_t kFileIOOpen(EngineState *s, int argc, reg_t *argv) {
|
|||
// Create a virtual file containing the save game description
|
||||
// and avatar ID, as the game scripts expect.
|
||||
int saveNo;
|
||||
sscanf(name.c_str(), "%d.DTA", &saveNo);
|
||||
|
||||
// The 4-language release uses a slightly different filename
|
||||
// structure that includes the letter of the language at the start
|
||||
// of the filename
|
||||
const int skip = name.firstChar() < '0' || name.firstChar() > '9';
|
||||
|
||||
if (sscanf(name.c_str() + skip, "%i.DTA", &saveNo) != 1) {
|
||||
warning("Could not parse game filename %s", name.c_str());
|
||||
}
|
||||
|
||||
saveNo += kSaveIdShift;
|
||||
|
||||
SavegameDesc save;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue