mirror of https://github.com/OpenRCT2/OpenRCT2.git
Add location to error messages
This commit is contained in:
parent
257c2d45d3
commit
226fc4cb00
|
@ -77,7 +77,7 @@ GameActions::Result FootpathAdditionPlaceAction::Query() const
|
|||
auto tileElement = MapGetFootpathElement(_loc);
|
||||
if (tileElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Could not find path element.");
|
||||
LOG_ERROR("Could not find path element at x = %d, y = %d, z = %d", _loc.x, _loc.y, _loc.z);
|
||||
return GameActions::Result(GameActions::Status::InvalidParameters, STR_CANT_POSITION_THIS_HERE, STR_NONE);
|
||||
}
|
||||
|
||||
|
@ -153,7 +153,7 @@ GameActions::Result FootpathAdditionPlaceAction::Execute() const
|
|||
|
||||
if (pathElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Could not find path element.");
|
||||
LOG_ERROR("Could not find path element at x = %d, y = %d, z = %d", _loc.x, _loc.y, _loc.z);
|
||||
return GameActions::Result(GameActions::Status::InvalidParameters, STR_CANT_POSITION_THIS_HERE, STR_NONE);
|
||||
}
|
||||
|
||||
|
|
|
@ -69,14 +69,14 @@ GameActions::Result FootpathAdditionRemoveAction::Query() const
|
|||
auto tileElement = MapGetFootpathElement(_loc);
|
||||
if (tileElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Could not find path element.");
|
||||
LOG_ERROR("Could not find path element at x = %d, y = %d, z = %d", _loc.x, _loc.y, _loc.z);
|
||||
return GameActions::Result(GameActions::Status::InvalidParameters, STR_CANT_REMOVE_THIS, STR_NONE);
|
||||
}
|
||||
|
||||
auto pathElement = tileElement->AsPath();
|
||||
if (pathElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Could not find path element.");
|
||||
LOG_ERROR("Could not find path element at x = %d, y = %d, z = %d", _loc.x, _loc.y, _loc.z);
|
||||
return GameActions::Result(GameActions::Status::InvalidParameters, STR_CANT_REMOVE_THIS, STR_NONE);
|
||||
}
|
||||
|
||||
|
@ -101,7 +101,7 @@ GameActions::Result FootpathAdditionRemoveAction::Execute() const
|
|||
|
||||
if (pathElement == nullptr)
|
||||
{
|
||||
LOG_ERROR("Could not find path element.");
|
||||
LOG_ERROR("Could not find path element at x = %d, y = %d, z = %d", _loc.x, _loc.y, _loc.z);
|
||||
return GameActions::Result(GameActions::Status::InvalidParameters, STR_CANT_REMOVE_THIS, STR_NONE);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue