1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-18 12:33:17 +01:00

Fix #14409: NPE when demolishing banner

This commit is contained in:
Gymnasiast
2021-04-03 22:09:24 +02:00
parent 943e89d5a6
commit f5ec127eaf

View File

@@ -172,6 +172,9 @@ public:
break;
case WIDX_BANNER_DEMOLISH:
{
if (_banner == nullptr || _tileElement == nullptr)
break;
auto bannerRemoveAction = BannerRemoveAction(
{ _banner->position.ToCoordsXY(), _tileElement->GetBaseZ(), _tileElement->GetPosition() });
GameActions::Execute(&bannerRemoveAction);