Skip to content

Commit

Permalink
Show a warning dialog upon a map file loading failure (#9278)
Browse files Browse the repository at this point in the history
  • Loading branch information
ihhub authored Dec 14, 2024
1 parent 2299929 commit 08d6434
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/fheroes2/game/game_scenarioinfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,8 @@ namespace
return fheroes2::GameMode::START_GAME;
}

fheroes2::drawMainMenuScreen();
fheroes2::showStandardTextMessage( _( "Warning" ), _( "The map is corrupted." ), Dialog::OK );
return fheroes2::GameMode::MAIN_MENU;
}

Expand All @@ -447,6 +449,8 @@ namespace
return fheroes2::GameMode::START_GAME;
}

fheroes2::drawMainMenuScreen();
fheroes2::showStandardTextMessage( _( "Warning" ), _( "The map is corrupted." ), Dialog::OK );
return fheroes2::GameMode::MAIN_MENU;
}
}
Expand Down

0 comments on commit 08d6434

Please sign in to comment.