1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-16 19:43:06 +01:00

Add braces to fix return on null Coords

This commit is contained in:
Tulio Leao
2019-11-21 09:22:09 -03:00
committed by GitHub
parent a9c2e1229a
commit 7f74e01669

View File

@@ -1379,8 +1379,10 @@ static void sub_6E1F34(
auto mapCoords = screen_get_map_xy_quadrant_with_z({ x, y }, z, &cl);
if (!mapCoords)
{
*grid_x = LOCATION_NULL;
return;
}
*grid_x = mapCoords->x;
*grid_y = mapCoords->y;
// If SHIFT pressed
@@ -1562,8 +1564,10 @@ static void sub_6E1F34(
int16_t z = gSceneryCtrlPressZ;
auto mapCoords = screen_get_map_xy_side_with_z({ x, y }, z, &cl);
if (!mapCoords)
{
*grid_x = LOCATION_NULL;
return;
}
*grid_x = mapCoords->x;
*grid_y = mapCoords->y;