From e32518208fb282d2aa98730421dd2b5449f7e7c3 Mon Sep 17 00:00:00 2001 From: Michael Steenbeek Date: Sun, 15 Mar 2020 23:26:32 +0100 Subject: [PATCH] Fix Clear Scenery refunding ghost tile elements (#10941) --- distribution/changelog.txt | 1 + src/openrct2/actions/ClearAction.hpp | 3 +++ 2 files changed, 4 insertions(+) diff --git a/distribution/changelog.txt b/distribution/changelog.txt index f6343bcb4d..c7cedadb25 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -34,6 +34,7 @@ - Fix: [#10822] Can place too many peep spawns. - Fix: [#10898] Banner text has an offset in tile inspector window. - Fix: [#10904] RCT1/LL-scenarios with red water won't open. +- Fix: [#10941] The Clear Scenery tool gives refunds for ghost elements. - Improved: [#682] The staff patrol area is now drawn on the water, instead of on the surface under water. - Improved: [#10858] Added horizontal grid lines to finance charts. - Improved: [#10884] Added y-axes and labels to park window charts. diff --git a/src/openrct2/actions/ClearAction.hpp b/src/openrct2/actions/ClearAction.hpp index c88b32577a..d37b14b6f3 100644 --- a/src/openrct2/actions/ClearAction.hpp +++ b/src/openrct2/actions/ClearAction.hpp @@ -148,6 +148,9 @@ private: return totalCost; do { + if (tileElement->IsGhost()) + continue; + auto type = tileElement->GetType(); switch (type) {