| 167 | bool game_paused_by_player = false; ///< True if the game was paused by the player when the highscore window was opened. |
| 168 | |
| 169 | HighScoreWindow(WindowDesc &desc, int difficulty, int8_t ranking) : EndGameHighScoreBaseWindow(desc) |
| 170 | { |
| 171 | /* pause game to show the chart */ |
| 172 | this->game_paused_by_player = _pause_mode == PauseMode::Normal; |
| 173 | if (!_networking && !this->game_paused_by_player) Command<CMD_PAUSE>::Post(PauseMode::Normal, true); |
| 174 | |
| 175 | /* Close all always on-top windows to get a clean screen */ |
| 176 | if (_game_mode != GM_MENU) HideVitalWindows(); |
| 177 | |
| 178 | MarkWholeScreenDirty(); |
| 179 | this->window_number = difficulty; // show highscore chart for difficulty... |
| 180 | this->background_img = SPR_HIGHSCORE_CHART_BEGIN; // which background to show |
| 181 | this->rank = ranking; |
| 182 | } |
| 183 | |
| 184 | void Close([[maybe_unused]] int data = 0) override |
| 185 | { |
nothing calls this directly
no test coverage detected