From 1aed54f106e8cf28a00d7223b42a0af71d4383e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=B6eh=20Matt?= <5415177+ZehMatt@users.noreply.github.com> Date: Thu, 21 Oct 2021 20:51:09 +0300 Subject: [PATCH] Refactor explicit constructor usage in Peep::Place --- src/openrct2/peep/Peep.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/openrct2/peep/Peep.cpp b/src/openrct2/peep/Peep.cpp index 1a7eb5a5d4..7d3733c8c7 100644 --- a/src/openrct2/peep/Peep.cpp +++ b/src/openrct2/peep/Peep.cpp @@ -582,7 +582,8 @@ std::unique_ptr Peep::Place(const TileCoordsXYZ& location, } if (tileElement == nullptr) { - return std::make_unique(GameActions::Status::InvalidParameters, STR_ERR_CANT_PLACE_PERSON_HERE); + return std::make_unique( + GameActions::Status::InvalidParameters, STR_ERR_CANT_PLACE_PERSON_HERE, STR_NONE); } // Set the coordinate of destination to be exactly @@ -591,7 +592,7 @@ std::unique_ptr Peep::Place(const TileCoordsXYZ& location, if (!map_is_location_owned(destination)) { - return std::make_unique(GameActions::Status::NotOwned, STR_ERR_CANT_PLACE_PERSON_HERE); + return std::make_unique(GameActions::Status::NotOwned, STR_ERR_CANT_PLACE_PERSON_HERE, STR_NONE); } if (auto res = MapCanConstructAt({ destination, destination.z, destination.z + (1 * 8) }, { 0b1111, 0 });