mirror of
https://github.com/rosebudai/OpenRCT2-Web.git
synced 2026-12-06 21:21:50 +01:00
Rename members of GameActions::Status
This commit is contained in:
110 files changed
+728
-728
No files matched your search
@@ -113,13 +113,13 @@ namespace OpenRCT2::GameActions
|
||||
LOG_ERROR(
|
||||
"Track Element not found. x = %d, y = %d, z = %d, d = %d, seq = %d.", _origin.x, _origin.y, _origin.z,
|
||||
_origin.direction, _sequence);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
if (tileElement->AsTrack()->IsIndestructible())
|
||||
{
|
||||
return Result(
|
||||
Status::Disallowed, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_YOU_ARE_NOT_ALLOWED_TO_REMOVE_THIS_SECTION);
|
||||
Status::disallowed, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_YOU_ARE_NOT_ALLOWED_TO_REMOVE_THIS_SECTION);
|
||||
}
|
||||
|
||||
RideId rideIndex = tileElement->AsTrack()->GetRideIndex();
|
||||
@@ -129,20 +129,20 @@ namespace OpenRCT2::GameActions
|
||||
if (ride == nullptr)
|
||||
{
|
||||
LOG_ERROR("Ride not found for rideIndex %d.", rideIndex);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_RIDE_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_RIDE_NOT_FOUND);
|
||||
}
|
||||
|
||||
if (ride->type >= RIDE_TYPE_COUNT)
|
||||
{
|
||||
LOG_ERROR("Ride type not found. ride type = %d.", ride->type);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_VALUE_OUT_OF_RANGE);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_VALUE_OUT_OF_RANGE);
|
||||
}
|
||||
const auto& ted = GetTrackElementDescriptor(trackType);
|
||||
auto sequenceIndex = tileElement->AsTrack()->GetSequenceIndex();
|
||||
if (sequenceIndex >= ted.numSequences)
|
||||
{
|
||||
LOG_ERROR("Track block %d not found for track type %d.", sequenceIndex, trackType);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_BLOCK_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_BLOCK_NOT_FOUND);
|
||||
}
|
||||
const auto& currentTrackBlock = ted.sequences[sequenceIndex].clearance;
|
||||
|
||||
@@ -168,7 +168,7 @@ namespace OpenRCT2::GameActions
|
||||
|
||||
if (!LocationValid(mapLoc))
|
||||
{
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_OFF_EDGE_OF_MAP);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_OFF_EDGE_OF_MAP);
|
||||
}
|
||||
MapInvalidateTileFull(mapLoc);
|
||||
|
||||
@@ -206,7 +206,7 @@ namespace OpenRCT2::GameActions
|
||||
LOG_ERROR(
|
||||
"Track Element not found. x = %d, y = %d, z = %d, d = %d, seq = %d.", mapLoc.x, mapLoc.y, mapLoc.z,
|
||||
_origin.direction, i);
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
int32_t entranceDirections = ted.sequences[0].flags;
|
||||
@@ -215,7 +215,7 @@ namespace OpenRCT2::GameActions
|
||||
const auto removeElementResult = TrackRemoveStationElement({ mapLoc, _origin.direction }, rideIndex, {});
|
||||
if (!removeElementResult.Successful)
|
||||
{
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -223,7 +223,7 @@ namespace OpenRCT2::GameActions
|
||||
if (surfaceElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Surface Element not found. x = %d, y = %d", mapLoc.x, mapLoc.y);
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_SURFACE_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_SURFACE_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
int16_t _support_height = tileElement->BaseHeight - surfaceElement->BaseHeight;
|
||||
@@ -297,7 +297,7 @@ namespace OpenRCT2::GameActions
|
||||
LOG_ERROR(
|
||||
"Track Element not found. x = %d, y = %d, z = %d, d = %d, seq = %d.", _origin.x, _origin.y, _origin.z,
|
||||
_origin.direction, _sequence);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
RideId rideIndex = tileElement->AsTrack()->GetRideIndex();
|
||||
@@ -308,14 +308,14 @@ namespace OpenRCT2::GameActions
|
||||
if (ride == nullptr)
|
||||
{
|
||||
LOG_ERROR("Ride not found. ride index = %d.", rideIndex);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_RIDE_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_RIDE_NOT_FOUND);
|
||||
}
|
||||
const auto& ted = GetTrackElementDescriptor(trackType);
|
||||
auto sequenceIndex = tileElement->AsTrack()->GetSequenceIndex();
|
||||
if (sequenceIndex >= ted.numSequences)
|
||||
{
|
||||
LOG_ERROR("Track block %d not found for track type %d.", sequenceIndex, trackType);
|
||||
return Result(Status::InvalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_BLOCK_NOT_FOUND);
|
||||
return Result(Status::invalidParameters, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_BLOCK_NOT_FOUND);
|
||||
}
|
||||
|
||||
auto startLoc = _origin;
|
||||
@@ -376,7 +376,7 @@ namespace OpenRCT2::GameActions
|
||||
LOG_ERROR(
|
||||
"Track Element not found. x = %d, y = %d, z = %d, d = %d, seq = %d.", mapLoc.x, mapLoc.y, mapLoc.z,
|
||||
_origin.direction, i);
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_TRACK_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
int32_t entranceDirections = ted.sequences[0].flags;
|
||||
@@ -385,7 +385,7 @@ namespace OpenRCT2::GameActions
|
||||
const auto removeElementResult = TrackRemoveStationElement({ mapLoc, _origin.direction }, rideIndex, {});
|
||||
if (!removeElementResult.Successful)
|
||||
{
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -393,7 +393,7 @@ namespace OpenRCT2::GameActions
|
||||
if (surfaceElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Surface Element not found. x = %d, y = %d", mapLoc.x, mapLoc.y);
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_SURFACE_ELEMENT_NOT_FOUND);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_ERR_SURFACE_ELEMENT_NOT_FOUND);
|
||||
}
|
||||
|
||||
int16_t _support_height = tileElement->BaseHeight - surfaceElement->BaseHeight;
|
||||
@@ -414,7 +414,7 @@ namespace OpenRCT2::GameActions
|
||||
{ mapLoc, _origin.direction }, rideIndex, { CommandFlag::apply });
|
||||
if (!removeElementResult.Successful)
|
||||
{
|
||||
return Result(Status::Unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
return Result(Status::unknown, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, removeElementResult.Message);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user