1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-22 14:24:33 +01:00

Remove use of std::variant

This commit is contained in:
Ted John
2020-04-20 23:30:37 +01:00
parent 940cd6db73
commit e1c08defc8
9 changed files with 70 additions and 20 deletions

View File

@@ -1324,7 +1324,7 @@ static GameActionResult::Ptr map_can_construct_with_clear_at(
if (tileElement == nullptr)
{
res->Error = GA_ERROR::UNKNOWN;
res->ErrorMessage = 0;
res->ErrorMessage = STR_NONE;
return res;
}
do
@@ -1481,7 +1481,7 @@ bool map_can_construct_with_clear_at(
uint8_t crossingMode)
{
GameActionResult::Ptr res = map_can_construct_with_clear_at(pos, clearFunc, quarterTile, flags, crossingMode);
if (auto message = std::get_if<rct_string_id>(&res->ErrorMessage))
if (auto message = res->ErrorMessage.AsStringId())
gGameCommandErrorText = *message;
else
gGameCommandErrorText = STR_NONE;