* Initialise the default colours (remaps and the likes), and load the main windows. */
| 551 | * Initialise the default colours (remaps and the likes), and load the main windows. |
| 552 | */ |
| 553 | void SetupColoursAndInitialWindow() |
| 554 | { |
| 555 | for (Colours i = COLOUR_BEGIN; i != COLOUR_END; i++) { |
| 556 | const uint8_t *b = GetNonSprite(GetColourPalette(i), SpriteType::Recolour) + 1; |
| 557 | assert(b != nullptr); |
| 558 | for (ColourShade j = SHADE_BEGIN; j < SHADE_END; j++) { |
| 559 | SetColourGradient(i, j, PixelColour{b[0xC6 + j]}); |
| 560 | } |
| 561 | } |
| 562 | |
| 563 | new MainWindow(_main_window_desc); |
| 564 | |
| 565 | /* XXX: these are not done */ |
| 566 | switch (_game_mode) { |
| 567 | default: NOT_REACHED(); |
| 568 | case GM_MENU: |
| 569 | ShowSelectGameWindow(); |
| 570 | break; |
| 571 | |
| 572 | case GM_NORMAL: |
| 573 | case GM_EDITOR: |
| 574 | ShowVitalWindows(); |
| 575 | break; |
| 576 | } |
| 577 | } |
| 578 | |
| 579 | /** |
| 580 | * Show the vital in-game windows. |
no test coverage detected