AGS: Restore screenshot creation workaround on save

This commit restores the old workaround to force screenshot creation on save,
which was lost among the upstream commits
Fixes bug #14477
This commit is contained in:
Walter Agazzi 2023-06-07 16:17:15 +02:00
parent 330aab7602
commit a7d69a40cb

View File

@ -880,7 +880,10 @@ void save_game(int slotn, const char *descript) {
VALIDATE_STRING(descript);
String nametouse = get_save_game_path(slotn);
std::unique_ptr<Bitmap> screenShot;
if (_GP(game).options[OPT_SAVESCREENSHOT] != 0)
// WORKAROUND: AGS originally only creates savegames if the game flags
// that it supports it. But we want it all the time for ScummVM GMM
if (/*_GP(game).options[OPT_SAVESCREENSHOT] != 0*/ true)
screenShot.reset(create_savegame_screenshot());
std::unique_ptr<Stream> out(StartSavegame(nametouse, descript, screenShot.get()));