From 45381b099753665ba98ab6908084fe0fdf95d990 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=B6eh=20Matt?= Date: Mon, 22 Oct 2018 18:51:36 +0200 Subject: [PATCH] Fix #8064: Check clearance height before alignment on correct z. (#8135) --- src/openrct2/ride/Track.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/openrct2/ride/Track.cpp b/src/openrct2/ride/Track.cpp index 11d333ba62..4b54fa5673 100644 --- a/src/openrct2/ride/Track.cpp +++ b/src/openrct2/ride/Track.cpp @@ -1173,7 +1173,7 @@ static money32 track_place( if (trackFlags[type] & TRACK_ELEM_FLAG_STARTS_AT_HALF_HEIGHT) { - if ((z & 0x0F) != 8) + if ((originZ & 0x0F) != 8) { gGameCommandErrorText = STR_CONSTRUCTION_ERR_UNKNOWN; return MONEY32_UNDEFINED; @@ -1181,7 +1181,7 @@ static money32 track_place( } else { - if ((z & 0x0F) != 0) + if ((originZ & 0x0F) != 0) { gGameCommandErrorText = STR_CONSTRUCTION_ERR_UNKNOWN; return MONEY32_UNDEFINED;