From 38c7a70025e7cd2054ea04c66a4bd68ffb7de4a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=B6eh=20Matt?= Date: Sun, 23 May 2021 15:45:48 +0300 Subject: [PATCH] Fix #14710: Preview not shown without enough money (#14711) * Fix #14710: Preview not shown without enough money * Bump up network version * Add changelog.txt entry --- distribution/changelog.txt | 1 + src/openrct2/actions/GameAction.cpp | 3 ++- src/openrct2/network/NetworkBase.cpp | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/distribution/changelog.txt b/distribution/changelog.txt index eda7cd7591..88d71712d7 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -20,6 +20,7 @@ - Fix: [#14587] Confusing message when joining server with mismatched network version. - Fix: [#14604] American-style Steam Trains are not imported correctly from RCT1 saves. - Fix: [#14638] The “About OpenRCT2” window cannot be themed. +- Fix: [#14710] Ride/Track Design preview does not show if it costs more money than available. - Improved: [#14712]: Improve startup times. 0.3.3 (2021-03-13) diff --git a/src/openrct2/actions/GameAction.cpp b/src/openrct2/actions/GameAction.cpp index adc8606a62..f957c87d0a 100644 --- a/src/openrct2/actions/GameAction.cpp +++ b/src/openrct2/actions/GameAction.cpp @@ -310,7 +310,8 @@ namespace GameActions if (result->Error == GameActions::Status::Ok) { - if (!finance_check_affordability(result->Cost, action->GetFlags())) + if ((action->GetFlags() & GAME_COMMAND_FLAG_APPLY) + && !finance_check_affordability(result->Cost, action->GetFlags())) { result->Error = GameActions::Status::InsufficientFunds; result->ErrorTitle = STR_CANT_DO_THIS; diff --git a/src/openrct2/network/NetworkBase.cpp b/src/openrct2/network/NetworkBase.cpp index a80167a71f..dac50877fb 100644 --- a/src/openrct2/network/NetworkBase.cpp +++ b/src/openrct2/network/NetworkBase.cpp @@ -36,7 +36,7 @@ // This string specifies which version of network stream current build uses. // It is used for making sure only compatible builds get connected, even within // single OpenRCT2 version. -#define NETWORK_STREAM_VERSION "14" +#define NETWORK_STREAM_VERSION "15" #define NETWORK_STREAM_ID OPENRCT2_VERSION "-" NETWORK_STREAM_VERSION static Peep* _pickup_peep = nullptr;