diff --git a/src/ride/coaster/wooden_wild_mouse.c b/src/ride/coaster/wooden_wild_mouse.c index 32fba66998..18bf8d8436 100644 --- a/src/ride/coaster/wooden_wild_mouse.c +++ b/src/ride/coaster/wooden_wild_mouse.c @@ -26,7 +26,34 @@ #include "../track_data.h" #include "../track_paint.h" +enum { + SPR_WOODEN_WILD_MOUSE_FLAT_SW_NE = 28535, + SPR_WOODEN_WILD_MOUSE_FLAT_NW_SE = 28536, +}; + +static void wooden_wild_mouse_track_flat(uint8 rideIndex, uint8 trackSequence, uint8 direction, int height, rct_map_element * mapElement) +{ + static const uint32 imageIds[4] = { + SPR_WOODEN_WILD_MOUSE_FLAT_SW_NE, + SPR_WOODEN_WILD_MOUSE_FLAT_NW_SE, + SPR_WOODEN_WILD_MOUSE_FLAT_SW_NE, + SPR_WOODEN_WILD_MOUSE_FLAT_NW_SE, + }; + + uint32 imageId = imageIds[direction] | gTrackColours[SCHEME_TRACK]; + sub_98196C_rotated(direction, imageId, 0, 6, 32, 20, 1, height); + wooden_a_supports_paint_setup(direction & 1, 0, height, gTrackColours[SCHEME_SUPPORTS], NULL); + paint_util_push_tunnel_rotated(direction, height, TUNNEL_0); + paint_util_set_segment_support_height(paint_util_rotate_segments(SEGMENT_B4 | SEGMENT_B8 | SEGMENT_BC | SEGMENT_C0 | SEGMENT_C8 | SEGMENT_D4, direction), height, 0x20); + paint_util_set_segment_support_height(paint_util_rotate_segments(SEGMENT_C4 | SEGMENT_CC | SEGMENT_D0, direction), 0xFFFF, 0); + paint_util_set_general_support_height(height + 32, 0x20); +} + TRACK_PAINT_FUNCTION get_track_paint_function_wooden_wild_mouse(int trackType, int direction) { + switch (trackType) { + case TRACK_ELEM_FLAT: + return wooden_wild_mouse_track_flat; + } return NULL; }