mirror of https://github.com/OpenRCT2/OpenRCT2.git
Fix overload resolution for map_get_first_element_at
This commit is contained in:
parent
a3b0c9ac81
commit
79ab832000
|
@ -713,7 +713,7 @@ void Peep::UpdateFalling()
|
||||||
}
|
}
|
||||||
|
|
||||||
// If not drowning then falling. Note: peeps 'fall' after leaving a ride/enter the park.
|
// If not drowning then falling. Note: peeps 'fall' after leaving a ride/enter the park.
|
||||||
TileElement* tile_element = map_get_first_element_at({ x, y });
|
TileElement* tile_element = map_get_first_element_at(CoordsXY{ x, y });
|
||||||
TileElement* saved_map = nullptr;
|
TileElement* saved_map = nullptr;
|
||||||
int32_t saved_height = 0;
|
int32_t saved_height = 0;
|
||||||
|
|
||||||
|
|
|
@ -351,7 +351,7 @@ rct_string_id TrackDesign::CreateTrackDesignMaze(const Ride& ride)
|
||||||
{
|
{
|
||||||
for (; x < MAXIMUM_MAP_SIZE_BIG; x += COORDS_XY_STEP)
|
for (; x < MAXIMUM_MAP_SIZE_BIG; x += COORDS_XY_STEP)
|
||||||
{
|
{
|
||||||
auto tileElement = map_get_first_element_at({ x, y });
|
auto tileElement = map_get_first_element_at(CoordsXY{ x, y });
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
if (tileElement == nullptr)
|
if (tileElement == nullptr)
|
||||||
|
@ -457,7 +457,7 @@ CoordsXYE TrackDesign::MazeGetFirstElement(const Ride& ride)
|
||||||
{
|
{
|
||||||
for (tile.x = 0; tile.x < MAXIMUM_MAP_SIZE_BIG; tile.x += COORDS_XY_STEP)
|
for (tile.x = 0; tile.x < MAXIMUM_MAP_SIZE_BIG; tile.x += COORDS_XY_STEP)
|
||||||
{
|
{
|
||||||
tile.element = map_get_first_element_at({ tile.x, tile.y });
|
tile.element = map_get_first_element_at(CoordsXY{ tile.x, tile.y });
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
if (tile.element == nullptr)
|
if (tile.element == nullptr)
|
||||||
|
|
|
@ -1897,7 +1897,7 @@ void Vehicle::UpdateMeasurements()
|
||||||
{
|
{
|
||||||
// Set tile_element to first element. Since elements aren't always ordered by base height,
|
// Set tile_element to first element. Since elements aren't always ordered by base height,
|
||||||
// we must start at the first element and iterate through each tile element.
|
// we must start at the first element and iterate through each tile element.
|
||||||
auto tileElement = map_get_first_element_at({ x, y });
|
auto tileElement = map_get_first_element_at(CoordsXY{ x, y });
|
||||||
if (tileElement == nullptr)
|
if (tileElement == nullptr)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
|
@ -110,7 +110,7 @@ static void chairlift_paint_util_draw_supports(paint_session* session, int32_t s
|
||||||
static const TrackElement* chairlift_paint_util_map_get_track_element_at_from_ride_fuzzy(
|
static const TrackElement* chairlift_paint_util_map_get_track_element_at_from_ride_fuzzy(
|
||||||
int32_t x, int32_t y, int32_t z, const Ride* ride)
|
int32_t x, int32_t y, int32_t z, const Ride* ride)
|
||||||
{
|
{
|
||||||
const TileElement* tileElement = map_get_first_element_at({ x, y });
|
const TileElement* tileElement = map_get_first_element_at(CoordsXY{ x, y });
|
||||||
if (tileElement == nullptr)
|
if (tileElement == nullptr)
|
||||||
{
|
{
|
||||||
return nullptr;
|
return nullptr;
|
||||||
|
|
|
@ -243,7 +243,7 @@ void tile_element_iterator_begin(tile_element_iterator* it)
|
||||||
{
|
{
|
||||||
it->x = 0;
|
it->x = 0;
|
||||||
it->y = 0;
|
it->y = 0;
|
||||||
it->element = map_get_first_element_at({ 0, 0 });
|
it->element = map_get_first_element_at(TileCoordsXY{ 0, 0 });
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t tile_element_iterator_next(tile_element_iterator* it)
|
int32_t tile_element_iterator_next(tile_element_iterator* it)
|
||||||
|
|
Loading…
Reference in New Issue