From 728e5d5e1c81cd71247cf5fc3ba78c31471e82f8 Mon Sep 17 00:00:00 2001 From: Duncan Frost Date: Wed, 8 Jul 2015 18:46:32 +0100 Subject: [PATCH] Fix multiple station platforms. Small mistake was causing multiple station platforms to not be properly deleted from a rct_ride. Fixes #1566 --- src/ride/track.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ride/track.c b/src/ride/track.c index 3758dcb8e7..a07217f466 100644 --- a/src/ride/track.c +++ b/src/ride/track.c @@ -4087,7 +4087,7 @@ money32 track_remove(uint8 type, uint8 sequence, sint16 originX, sint16 originY, entranceDirections = RCT2_ADDRESS(0x0099BA64, uint8)[type * 16]; } - if (entranceDirections & (1 << 4) && (mapElement->properties.track.sequence == 0)){ + if (entranceDirections & (1 << 4) && ((mapElement->properties.track.sequence & 0xF) == 0)){ if (RCT2_CALLPROC_X(0x006C494B, x, (rideIndex << 8), y, (z / 8) | (rotation << 8), 0, 0, 0) & 0x100){ return MONEY32_UNDEFINED; } @@ -4108,7 +4108,7 @@ money32 track_remove(uint8 type, uint8 sequence, sint16 originX, sint16 originY, if (!(flags & GAME_COMMAND_FLAG_APPLY)) continue; - if (entranceDirections & (1 << 4) && (mapElement->properties.track.sequence == 0)){ + if (entranceDirections & (1 << 4) && ((mapElement->properties.track.sequence & 0xF) == 0)){ if (RCT2_CALLPROC_X(0x006C494B, x, GAME_COMMAND_FLAG_APPLY | (rideIndex << 8), y, (z / 8) | (rotation << 8), 0, 0, 0) & 0x100){ return MONEY32_UNDEFINED; }