1
0
Fork 0

Change: In the Editor, sync town layout setting with found towns buttons

pull/10409/head
Tyler Trahan 2024-06-26 12:24:12 -04:00
parent e08bc4d6e3
commit c8e60833ca
1 changed files with 5 additions and 0 deletions

View File

@ -1280,6 +1280,11 @@ public:
case WID_TF_LAYOUT_ORIGINAL: case WID_TF_LAYOUT_BETTER: case WID_TF_LAYOUT_GRID2:
case WID_TF_LAYOUT_GRID3: case WID_TF_LAYOUT_RANDOM:
this->town_layout = (TownLayout)(widget - WID_TF_LAYOUT_ORIGINAL);
/* If we are in the editor, sync the settings of the current game to the chosen layout,
* so that importing towns from file uses the selected layout. */
if (_game_mode == GM_EDITOR) _settings_game.economy.town_layout = this->town_layout;
this->UpdateButtons(false);
break;
}