From ee896a481e7bc0cd5f05994372c44e5041f96252 Mon Sep 17 00:00:00 2001 From: Ted John Date: Sat, 1 Oct 2016 17:06:12 +0100 Subject: [PATCH] Fix remaining Junior RC testpaint fails --- src/paint/paint_helpers.c | 2 +- src/ride/coaster/junior_roller_coaster.c | 12 +++++------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/src/paint/paint_helpers.c b/src/paint/paint_helpers.c index 41ddcc188b..54248b90b5 100644 --- a/src/paint/paint_helpers.c +++ b/src/paint/paint_helpers.c @@ -26,7 +26,7 @@ paint_struct * sub_98196C_rotated( sint16 z_offset) { if (direction & 1) { - return sub_98196C(image_id, x_offset, y_offset, bound_box_length_y, bound_box_length_x, bound_box_length_z, z_offset, get_current_rotation()); + return sub_98196C(image_id, y_offset, x_offset, bound_box_length_y, bound_box_length_x, bound_box_length_z, z_offset, get_current_rotation()); } else { return sub_98196C(image_id, x_offset, y_offset, bound_box_length_x, bound_box_length_y, bound_box_length_z, z_offset, get_current_rotation()); } diff --git a/src/ride/coaster/junior_roller_coaster.c b/src/ride/coaster/junior_roller_coaster.c index 3181d7474f..daa6d10aeb 100644 --- a/src/ride/coaster/junior_roller_coaster.c +++ b/src/ride/coaster/junior_roller_coaster.c @@ -1808,13 +1808,11 @@ static void junior_rc_flat_to_25_deg_up_paint_setup(uint8 rideIndex, uint8 track image_id |= junior_rc_track_pieces_flat_to_25_deg_up[isChained][direction]; - if (direction & 1) { - sub_98196C(image_id, 6, 0, 20, 32, 1, height, get_current_rotation()); - paint_util_push_tunnel_right(height, TUNNEL_0); - } - else { - sub_98196C(image_id, 0, 6, 32, 20, 1, height, get_current_rotation()); - paint_util_push_tunnel_left(height, TUNNEL_0); + sub_98196C_rotated(direction, image_id, 0, 6, 32, 20, 1, height); + if (direction == 0 || direction == 3) { + paint_util_push_tunnel_rotated(direction, height, TUNNEL_0); + } else { + paint_util_push_tunnel_rotated(direction, height, TUNNEL_2); } const rct_xy16 pos = {gPaintMapPosition.x, gPaintMapPosition.y};