From d27c9c0ec46341a2156c5c96e2adea6b6830fbaa Mon Sep 17 00:00:00 2001 From: IntelOrca Date: Sat, 27 Feb 2016 13:14:26 +0000 Subject: [PATCH] fix #3026: can construct maze when its open --- src/windows/maze_construction.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/windows/maze_construction.c b/src/windows/maze_construction.c index 1e0667a067..3b304e0c4f 100644 --- a/src/windows/maze_construction.c +++ b/src/windows/maze_construction.c @@ -291,6 +291,12 @@ static void window_maze_construction_mousedown(int widgetIndex, rct_window *w, r */ static void window_maze_construction_update(rct_window *w) { + rct_ride *ride = get_ride(_currentRideIndex); + if (ride == NULL || ride->status != RIDE_STATUS_CLOSED) { + window_close(w); + return; + } + switch (_rideConstructionState) { case RIDE_CONSTRUCTION_STATE_PLACE: if (!widget_is_active_tool(w, WIDX_MAZE_DIRECTION_GROUPBOX)) {