mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-18 20:43:04 +01:00
Draw flat to 25 deg up
This commit is contained in:
@@ -30,10 +30,14 @@ enum
|
||||
SPR_MONORAIL_FLAT_NW_SE = 23232,
|
||||
|
||||
SPR_MONORAIL_25_DEG_UP_SW_NE = 23253,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_SW_NE = 23254,
|
||||
SPR_MONORAIL_25_DEG_UP_NE_SW = 23255,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_NE_SW = 23256,
|
||||
|
||||
SPR_MONORAIL_25_DEG_UP_NW_SE = 23259,
|
||||
SPR_MONORAIL_25_DEG_UP_SE_NW = 23260,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_NW_SE = 23261,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_SE_NW = 23262,
|
||||
|
||||
SPR_MONORAIL_EIGHT_TO_DIAG_SW_E_PART_0 = 23293,
|
||||
SPR_MONORAIL_EIGHT_TO_DIAG_SW_E_PART_1 = 23294,
|
||||
@@ -83,6 +87,13 @@ static const uint32 monorail_track_pieces_25_deg_up[4] = {
|
||||
SPR_MONORAIL_25_DEG_UP_SE_NW,
|
||||
};
|
||||
|
||||
static const uint32 monorail_track_pieces_flat_to_25_deg_up[4] = {
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_SW_NE,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_NW_SE,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_NE_SW,
|
||||
SPR_MONORAIL_FLAT_TO_25_DEG_UP_SE_NW,
|
||||
};
|
||||
|
||||
static const uint32 ghost_train_track_pieces_right_eight_to_diag[4][4] = {
|
||||
{
|
||||
SPR_MONORAIL_EIGHT_TO_DIAG_SW_E_PART_0,
|
||||
@@ -305,9 +316,32 @@ static void paint_monorail_track_25_deg_up(uint8 rideIndex, uint8 trackSequence,
|
||||
paint_util_set_general_support_height(height + 56, 0x20);
|
||||
}
|
||||
|
||||
/** rct2: 0x */
|
||||
/** rct2: 0x008AE1CC */
|
||||
static void paint_monorail_track_flat_to_25_deg_up(uint8 rideIndex, uint8 trackSequence, uint8 direction, int height, rct_map_element * mapElement)
|
||||
{
|
||||
rct_xy16 position = {RCT2_GLOBAL(0x009DE56A, sint16), RCT2_GLOBAL(0x009DE56E, sint16)};
|
||||
|
||||
uint32 imageId = monorail_track_pieces_flat_to_25_deg_up[direction] | RCT2_GLOBAL(0x00F44198, uint32);
|
||||
|
||||
if (direction == 0 || direction == 2) {
|
||||
sub_98196C(imageId, 0, 6, 32, 20, 3, height, get_current_rotation());
|
||||
} else {
|
||||
sub_98196C(imageId, 6, 0, 20, 32, 3, height, get_current_rotation());
|
||||
}
|
||||
|
||||
switch (direction) {
|
||||
case 0: paint_util_push_tunnel_left(height, TUNNEL_6); break;
|
||||
case 1: paint_util_push_tunnel_right(height, TUNNEL_8); break;
|
||||
case 2: paint_util_push_tunnel_left(height, TUNNEL_8); break;
|
||||
case 3: paint_util_push_tunnel_right(height, TUNNEL_6); break;
|
||||
}
|
||||
|
||||
if (track_paint_util_should_paint_supports(position)) {
|
||||
metal_a_supports_paint_setup(3, 4, 3, height, RCT2_GLOBAL(0x00F4419C, uint32));
|
||||
}
|
||||
|
||||
paint_util_set_segment_support_height(paint_util_rotate_segments(SEGMENT_D0 | SEGMENT_C4 | SEGMENT_CC, direction), 0xFFFF, 0);
|
||||
paint_util_set_general_support_height(height + 48, 0x20);
|
||||
}
|
||||
|
||||
/** rct2: 0x */
|
||||
@@ -326,9 +360,10 @@ static void paint_monorail_track_flat_to_25_deg_down(uint8 rideIndex, uint8 trac
|
||||
{
|
||||
}
|
||||
|
||||
/** rct2: 0x */
|
||||
/** rct2: 0x008AE20C */
|
||||
static void paint_monorail_track_25_deg_down_to_flat(uint8 rideIndex, uint8 trackSequence, uint8 direction, int height, rct_map_element * mapElement)
|
||||
{
|
||||
paint_monorail_track_flat_to_25_deg_up(rideIndex, trackSequence, (direction + 2) % 4, height, mapElement);
|
||||
}
|
||||
|
||||
/** rct2: 0x */
|
||||
|
||||
Reference in New Issue
Block a user