mirror of https://github.com/OpenRCT2/OpenRCT2.git
Part of #16152: Use BoundBoxXYZ for PaintAddImageAsChild
This commit is contained in:
parent
540e5d248b
commit
76faa77f6b
|
@ -2821,7 +2821,10 @@ void Peep::Paint(PaintSession& session, int32_t imageDirection) const
|
|||
// bound_box_offset_z to make sure peeps are drawn on top of railways
|
||||
uint32_t baseImageId = (imageDirection >> 3) + GetPeepAnimation(SpriteType, actionSpriteType).base_image + imageOffset * 4;
|
||||
auto imageId = ImageId(baseImageId, TshirtColour, TrousersColour);
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, z }, { 1, 1, 11 }, { 0, 0, z + 5 });
|
||||
|
||||
auto bb = BoundBoxXYZ{ { 0, 0, z + 5 }, { 1, 1, 11 } };
|
||||
auto offset = CoordsXYZ{ 0, 0, z };
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, z }, bb);
|
||||
|
||||
auto* guest = As<Guest>();
|
||||
if (guest != nullptr)
|
||||
|
@ -2829,21 +2832,21 @@ void Peep::Paint(PaintSession& session, int32_t imageDirection) const
|
|||
if (baseImageId >= 10717 && baseImageId < 10749)
|
||||
{
|
||||
imageId = ImageId(baseImageId + 32, guest->HatColour);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, z }, { 1, 1, 11 }, { 0, 0, z + 5 });
|
||||
PaintAddImageAsChild(session, imageId, offset, bb);
|
||||
return;
|
||||
}
|
||||
|
||||
if (baseImageId >= 10781 && baseImageId < 10813)
|
||||
{
|
||||
imageId = ImageId(baseImageId + 32, guest->BalloonColour);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, z }, { 1, 1, 11 }, { 0, 0, z + 5 });
|
||||
PaintAddImageAsChild(session, imageId, offset, bb);
|
||||
return;
|
||||
}
|
||||
|
||||
if (baseImageId >= 11197 && baseImageId < 11229)
|
||||
{
|
||||
imageId = ImageId(baseImageId + 32, guest->UmbrellaColour);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, z }, { 1, 1, 11 }, { 0, 0, z + 5 });
|
||||
PaintAddImageAsChild(session, imageId, offset, bb);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -757,13 +757,6 @@ PaintStruct* PaintAddImageAsParent(
|
|||
return CreateNormalPaintStruct(session, imageId, offset, boundBox);
|
||||
}
|
||||
|
||||
PaintStruct* PaintAddImageAsChild(
|
||||
PaintSession& session, const ImageId imageId, const CoordsXYZ& offset, const CoordsXYZ& boundBoxLength,
|
||||
const CoordsXYZ& boundBoxOffset)
|
||||
{
|
||||
return PaintAddImageAsChild(session, imageId, offset, { boundBoxOffset, boundBoxLength });
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x006874B0, 0x00687618, 0x0068778C, 0x00687902, 0x0098199C
|
||||
|
|
|
@ -303,9 +303,6 @@ PaintStruct* PaintAddImageAsParent(
|
|||
PaintSession& session, const ImageId image_id, const CoordsXYZ& offset, const BoundBoxXYZ& boundBox);
|
||||
[[nodiscard]] PaintStruct* PaintAddImageAsOrphan(
|
||||
PaintSession& session, const ImageId image_id, const CoordsXYZ& offset, const BoundBoxXYZ& boundBox);
|
||||
PaintStruct* PaintAddImageAsChild(
|
||||
PaintSession& session, const ImageId image_id, const CoordsXYZ& offset, const CoordsXYZ& boundBoxLength,
|
||||
const CoordsXYZ& boundBoxOffset);
|
||||
PaintStruct* PaintAddImageAsChild(
|
||||
PaintSession& session, const ImageId image_id, const CoordsXYZ& offset, const BoundBoxXYZ& boundBox);
|
||||
|
||||
|
|
|
@ -45,11 +45,11 @@ PaintStruct* PaintAddImageAsChildRotated(
|
|||
if (direction & 1)
|
||||
{
|
||||
return PaintAddImageAsChild(
|
||||
session, image_id, { offset.y, offset.x, offset.z }, { boundBoxSize.y, boundBoxSize.x, boundBoxSize.z },
|
||||
{ boundBoxOffset.y, boundBoxOffset.x, boundBoxOffset.z });
|
||||
session, image_id, { offset.y, offset.x, offset.z },
|
||||
{ { boundBoxOffset.y, boundBoxOffset.x, boundBoxOffset.z }, { boundBoxSize.y, boundBoxSize.x, boundBoxSize.z } });
|
||||
}
|
||||
|
||||
return PaintAddImageAsChild(session, image_id, offset, boundBoxSize, boundBoxOffset);
|
||||
return PaintAddImageAsChild(session, image_id, offset, { boundBoxOffset, boundBoxSize });
|
||||
}
|
||||
|
||||
void PaintUtilPushTunnelRotated(PaintSession& session, uint8_t direction, uint16_t height, uint8_t type)
|
||||
|
|
|
@ -64,7 +64,7 @@ static void PaintBannerScrollingText(
|
|||
auto stringWidth = gfx_get_string_width(text, FontStyle::Tiny);
|
||||
auto scroll = (gCurrentTicks / 2) % stringWidth;
|
||||
auto imageId = scrolling_text_setup(session, STR_BANNER_TEXT_FORMAT, ft, scroll, scrollingMode, COLOUR_BLACK);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 22 }, { 1, 1, 21 }, bbOffset);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 22 }, { bbOffset, { 1, 1, 21 } });
|
||||
}
|
||||
|
||||
void PaintBanner(PaintSession& session, uint8_t direction, int32_t height, const BannerElement& bannerElement)
|
||||
|
|
|
@ -74,7 +74,7 @@ static void PaintRideEntranceExitScrollingText(
|
|||
|
||||
PaintAddImageAsChild(
|
||||
session, scrolling_text_setup(session, STR_BANNER_TEXT_FORMAT, ft, scroll, stationObj.ScrollingMode, COLOUR_BLACK),
|
||||
{ 0, 0, height + stationObj.Height }, { 28, 28, 51 }, { 2, 2, height + stationObj.Height });
|
||||
{ 0, 0, height + stationObj.Height }, { { 2, 2, height + stationObj.Height }, { 28, 28, 51 } });
|
||||
}
|
||||
|
||||
static void PaintRideEntranceExitLightEffects(PaintSession& session, int32_t height, const EntranceElement& entranceEl)
|
||||
|
|
|
@ -324,7 +324,7 @@ static void PaintLargeSceneryScrollingText(
|
|||
auto stringWidth = gfx_get_string_width(text, FontStyle::Tiny);
|
||||
auto scroll = stringWidth > 0 ? (gCurrentTicks / 2) % stringWidth : 0;
|
||||
auto imageId = scrolling_text_setup(session, STR_SCROLLING_SIGN_TEXT, ft, scroll, scrollMode, textPaletteIndex);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 25 }, { 1, 1, 21 }, bbOffset);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 25 }, { bbOffset, { 1, 1, 21 } });
|
||||
}
|
||||
|
||||
void PaintLargeScenery(PaintSession& session, uint8_t direction, uint16_t height, const LargeSceneryElement& tileElement)
|
||||
|
|
|
@ -471,7 +471,7 @@ static void PathPaintFencesAndQueueBanners(
|
|||
|
||||
PaintAddImageAsChild(
|
||||
session, scrolling_text_setup(session, STR_BANNER_TEXT_FORMAT, ft, scroll, scrollingMode, COLOUR_BLACK),
|
||||
{ 0, 0, height + 7 }, { 1, 1, 21 }, boundBoxOffsets);
|
||||
{ 0, 0, height + 7 }, { boundBoxOffsets, { 1, 1, 21 } });
|
||||
}
|
||||
|
||||
session.InteractionType = ViewportInteractionItem::Footpath;
|
||||
|
|
|
@ -184,7 +184,7 @@ static void PaintWallScrollingText(
|
|||
auto stringWidth = gfx_get_string_width(signString, FontStyle::Tiny);
|
||||
auto scroll = stringWidth > 0 ? (gCurrentTicks / 2) % stringWidth : 0;
|
||||
auto imageId = scrolling_text_setup(session, STR_SCROLLING_SIGN_TEXT, ft, scroll, scrollingMode, textPaletteIndex);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 8 }, { 1, 1, 13 }, boundsOffset);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 8 }, { boundsOffset, { 1, 1, 13 } });
|
||||
}
|
||||
|
||||
static void PaintWallWall(
|
||||
|
|
|
@ -298,17 +298,17 @@ void track_paint_util_paint_fences(
|
|||
if (edges & EDGE_NW && track_paint_util_has_fence(EDGE_NW, position, trackElement, ride, rotation))
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, colourFlags.WithIndex(fenceSprites[3]), { 0, 0, height }, { 32, 1, 7 }, { 0, 2, height + 2 });
|
||||
session, colourFlags.WithIndex(fenceSprites[3]), { 0, 0, height }, { { 0, 2, height + 2 }, { 32, 1, 7 } });
|
||||
}
|
||||
if (edges & EDGE_NE && track_paint_util_has_fence(EDGE_NE, position, trackElement, ride, rotation))
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, colourFlags.WithIndex(fenceSprites[0]), { 0, 0, height }, { 1, 32, 7 }, { 2, 0, height + 2 });
|
||||
session, colourFlags.WithIndex(fenceSprites[0]), { 0, 0, height }, { { 2, 0, height + 2 }, { 1, 32, 7 } });
|
||||
}
|
||||
if (edges & EDGE_SE && track_paint_util_has_fence(EDGE_SE, position, trackElement, ride, rotation))
|
||||
{
|
||||
PaintAddImageAsParent(
|
||||
session, colourFlags.WithIndex(fenceSprites[1]), { 0, 0, height }, { 32, 1, 7 }, { 0, 30, height + 2 });
|
||||
session, colourFlags.WithIndex(fenceSprites[1]), { 0, 0, height }, { { 0, 30, height + 2 }, { 32, 1, 7 } });
|
||||
}
|
||||
if (edges & EDGE_SW && track_paint_util_has_fence(EDGE_SW, position, trackElement, ride, rotation))
|
||||
{
|
||||
|
@ -2031,11 +2031,11 @@ void track_paint_util_spinning_tunnel_paint(PaintSession& session, int8_t thickn
|
|||
auto imageId = colourFlags.WithIndex(trackSpritesGhostTrainSpinningTunnel[direction & 1][0][frame]);
|
||||
if (direction == 0 || direction == 2)
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 28, 20, thickness }, { 2, 6, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 6, height }, { 28, 20, thickness } });
|
||||
}
|
||||
else
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 28, thickness }, { 6, 2, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 6, 2, height }, { 20, 28, thickness } });
|
||||
}
|
||||
|
||||
imageId = colourFlags.WithIndex(trackSpritesGhostTrainSpinningTunnel[direction & 1][1][frame]);
|
||||
|
|
|
@ -3520,7 +3520,7 @@ static void vehicle_visual_splash1_effect(PaintSession& session, int32_t z, cons
|
|||
}
|
||||
int32_t image_id = SPR_SPLASH_EFFECT_1_NE_0 + ((((vehicle->sprite_direction / 8) + session.CurrentRotation) & 3) * 8)
|
||||
+ ((gCurrentTicks / 2) & 7);
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { 0, 0, 0 }, { 0, 0, z });
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { { 0, 0, z }, { 0, 0, 0 } });
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -3543,7 +3543,7 @@ static void vehicle_visual_splash2_effect(PaintSession& session, int32_t z, cons
|
|||
}
|
||||
int32_t image_id = SPR_SPLASH_EFFECT_3_NE_0 + ((((vehicle->sprite_direction / 8) + session.CurrentRotation) & 3) * 8)
|
||||
+ ((gCurrentTicks / 2) & 7);
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { 0, 0, 0 }, { 0, 0, z });
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { { 0, 0, z }, { 0, 0, 0 } });
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -3566,7 +3566,7 @@ static void vehicle_visual_splash3_effect(PaintSession& session, int32_t z, cons
|
|||
}
|
||||
int32_t image_id = SPR_SPLASH_EFFECT_1_NE_0 + ((((vehicle->sprite_direction / 8) + session.CurrentRotation) & 3) * 8)
|
||||
+ ((gCurrentTicks / 2) & 7);
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { 0, 0, 0 }, { 0, 0, z });
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { { 0, 0, z }, { 0, 0, 0 } });
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -3594,7 +3594,7 @@ static void vehicle_visual_splash4_effect(PaintSession& session, int32_t z, cons
|
|||
}
|
||||
int32_t image_id = SPR_SPLASH_EFFECT_5_NE_0 + ((((vehicle->sprite_direction / 8) + session.CurrentRotation) & 3) * 8)
|
||||
+ ((gCurrentTicks / 2) & 7);
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { 1, 1, 0 }, { 0, 0, z });
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { { 0, 0, z }, { 1, 1, 0 } });
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -3626,7 +3626,7 @@ static void vehicle_visual_splash5_effect(PaintSession& session, int32_t z, cons
|
|||
}
|
||||
int32_t image_id = SPR_SPLASH_EFFECT_5_NE_0 + ((((vehicle->sprite_direction / 8) + session.CurrentRotation) & 3) * 8)
|
||||
+ ((gCurrentTicks / 2) & 7);
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { 1, 1, 0 }, { 0, 0, z });
|
||||
PaintAddImageAsChild(session, ImageId(image_id), { 0, 0, z }, { { 0, 0, z }, { 1, 1, 0 } });
|
||||
}
|
||||
|
||||
void vehicle_visual_splash_effect(PaintSession& session, int32_t z, const Vehicle* vehicle, const CarEntry* carEntry)
|
||||
|
|
|
@ -1855,7 +1855,7 @@ void junior_rc_paint_station(
|
|||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(junior_rc_track_pieces_station[false][direction]);
|
||||
}
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { 32, 20, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { { 0, 0, height }, { 32, 20, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 5, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 8, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
@ -1877,7 +1877,7 @@ void junior_rc_paint_station(
|
|||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(junior_rc_track_pieces_station[false][direction]);
|
||||
}
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { 20, 32, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { { 0, 0, height }, { 20, 32, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 6, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 7, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
|
|
@ -231,7 +231,7 @@ static void paint_reverse_freefall_rc_station(
|
|||
// height += 2 (height)
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(reverse_freefall_rc_track_pieces_station[direction]);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 20, 1 }, { 0, 6, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 6, height }, { 32, 20, 1 } });
|
||||
|
||||
WoodenASupportsPaintSetup(session, (direction & 1) ? 1 : 0, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
||||
|
@ -244,7 +244,7 @@ static void paint_reverse_freefall_rc_station(
|
|||
// height += 2 (height)
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(reverse_freefall_rc_track_pieces_station[direction]);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 32, 1 }, { 6, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 6, 0, height }, { 20, 32, 1 } });
|
||||
|
||||
WoodenASupportsPaintSetup(session, (direction & 1) ? 1 : 0, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
||||
|
|
|
@ -186,7 +186,9 @@ void vehicle_visual_virginia_reel(
|
|||
}
|
||||
}();
|
||||
baseImage_id += ecx & 7;
|
||||
const vehicle_boundbox* bb = &_virginiaReelBoundbox[baseImage_id >> 3];
|
||||
const auto& vehicleBb = _virginiaReelBoundbox[baseImage_id >> 3];
|
||||
auto bb = BoundBoxXYZ{ { vehicleBb.offset_x, vehicleBb.offset_y, vehicleBb.offset_z + z },
|
||||
{ vehicleBb.length_x, vehicleBb.length_y, vehicleBb.length_z } };
|
||||
|
||||
baseImage_id += carEntry->base_image_id;
|
||||
auto image_id = ImageId(baseImage_id, vehicle->colours.Body, vehicle->colours.Trim);
|
||||
|
@ -194,9 +196,7 @@ void vehicle_visual_virginia_reel(
|
|||
{
|
||||
image_id = ConstructionMarker.WithIndex(image_id.GetIndex());
|
||||
}
|
||||
PaintAddImageAsParent(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsParent(session, image_id, { 0, 0, z }, bb);
|
||||
|
||||
if (session.DPI.zoom_level < ZoomLevel{ 2 } && vehicle->num_peeps > 0 && !vehicle->IsGhost())
|
||||
{
|
||||
|
@ -211,9 +211,7 @@ void vehicle_visual_virginia_reel(
|
|||
if (riding_peep_sprites[i] != 0xFF)
|
||||
{
|
||||
image_id = ImageId(baseImage_id + ((i + 1) * 72), riding_peep_sprites[i]);
|
||||
PaintAddImageAsChild(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, bb);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -438,7 +436,7 @@ static void paint_virginia_reel_station(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 32, 28, 2 }, { 0, 2, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_VIRGINIA_REEL_FLAT_SW_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 20, 2 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 32, 20, 2 } });
|
||||
|
||||
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
||||
}
|
||||
|
@ -448,7 +446,7 @@ static void paint_virginia_reel_station(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 28, 32, 2 }, { 2, 0, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_VIRGINIA_REEL_FLAT_NW_SE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 32, 2 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 20, 32, 2 } });
|
||||
|
||||
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
||||
}
|
||||
|
|
|
@ -68,8 +68,8 @@ template<bool isClassic> void wooden_rc_track_paint_bb(PaintSession& session, co
|
|||
{
|
||||
ImageId railsImageId = wooden_rc_get_rails_colour(session).WithIndex(bb->sprite_id_b);
|
||||
PaintAddImageAsChild(
|
||||
session, railsImageId, { bb->offset.x, bb->offset.y, height + bb->offset.z }, bb->bb_size,
|
||||
{ bb->bb_offset.x, bb->bb_offset.y, height + bb->bb_offset.z });
|
||||
session, railsImageId, { bb->offset.x, bb->offset.y, height + bb->offset.z },
|
||||
{ { bb->bb_offset, height + bb->bb_offset.z }, bb->bb_size });
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -345,11 +345,11 @@ static void PaintCarRideStation(
|
|||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(CarRideTrackPiecesFlat[direction]);
|
||||
if (direction == 0 || direction == 2)
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { 32, 20, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { { 0, 0, height }, { 32, 20, 1 } });
|
||||
}
|
||||
else
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { 20, 32, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { { 0, 0, height }, { 20, 32, 1 } });
|
||||
}
|
||||
|
||||
if (direction == 0 || direction == 2)
|
||||
|
|
|
@ -130,12 +130,12 @@ static void PaintFerrisWheel(
|
|||
if (edges & EDGE_NW && track_paint_util_has_fence(EDGE_NW, session.MapPosition, trackElement, ride, rotation))
|
||||
{
|
||||
imageId = colourFlags.WithIndex(SPR_FENCE_ROPE_NW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 1, 7 }, { 0, 2, height + 2 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 2, height + 2 }, { 32, 1, 7 } });
|
||||
}
|
||||
if (edges & EDGE_NE && track_paint_util_has_fence(EDGE_NE, session.MapPosition, trackElement, ride, rotation))
|
||||
{
|
||||
imageId = colourFlags.WithIndex(SPR_FENCE_ROPE_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 1, 32, 7 }, { 2, 0, height + 2 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 0, height + 2 }, { 1, 32, 7 } });
|
||||
}
|
||||
if (edges & EDGE_SE && track_paint_util_has_fence(EDGE_SE, session.MapPosition, trackElement, ride, rotation))
|
||||
{
|
||||
|
|
|
@ -758,7 +758,7 @@ static void PaintMiniGolfTrackLeftQuarterTurn1Tile(
|
|||
break;
|
||||
|
||||
imageId = session.TrackColours[SCHEME_MISC].WithIndex(SprMiniGolfQuarterTurn1TileFenceBackSwNw);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 26, 24, 1 }, { 6, 2, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 6, 2, height }, { 26, 24, 1 } });
|
||||
|
||||
break;
|
||||
|
||||
|
@ -767,7 +767,7 @@ static void PaintMiniGolfTrackLeftQuarterTurn1Tile(
|
|||
break;
|
||||
|
||||
imageId = session.TrackColours[SCHEME_MISC].WithIndex(SprMiniGolfQuarterTurn1TileFenceBackNwNe);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 26, 26, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 26, 26, 1 } });
|
||||
break;
|
||||
|
||||
case 2:
|
||||
|
@ -776,7 +776,7 @@ static void PaintMiniGolfTrackLeftQuarterTurn1Tile(
|
|||
break;
|
||||
|
||||
imageId = session.TrackColours[SCHEME_MISC].WithIndex(SprMiniGolfQuarterTurn1TileFenceBackNeSe);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 24, 26, 1 }, { 2, 6, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 6, height }, { 24, 26, 1 } });
|
||||
break;
|
||||
|
||||
case 3:
|
||||
|
@ -786,7 +786,7 @@ static void PaintMiniGolfTrackLeftQuarterTurn1Tile(
|
|||
break;
|
||||
|
||||
imageId = session.TrackColours[SCHEME_MISC].WithIndex(SprMiniGolfQuarterTurn1TileFenceBackSeSw);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 24, 24, 1 }, { 6, 6, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 6, 6, height }, { 24, 24, 1 } });
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -852,26 +852,27 @@ static void PaintMiniGolfHoleAb(
|
|||
boundBoxOffset = { 0, 3 };
|
||||
}
|
||||
|
||||
auto bb = BoundBoxXYZ{ { boundBoxOffset, height + 24 }, { boundBox, 0 } };
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(sprites[direction][trackSequence][1]);
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 0 }, { boundBoxOffset.x, boundBoxOffset.y, height + 24 });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
bb.offset.z = height;
|
||||
bb.length.z = 1;
|
||||
|
||||
if (drewSupports)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_SUPPORTS].WithIndex(
|
||||
((direction & 1) ? SPR_FLOOR_PLANKS_90_DEG : SPR_FLOOR_PLANKS));
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(sprites[direction][trackSequence][0]);
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(sprites[direction][trackSequence][0]);
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -943,22 +944,20 @@ static void PaintMiniGolfHoleC(
|
|||
break;
|
||||
}
|
||||
|
||||
auto bb = BoundBoxXYZ{ { boundBoxOffset, height }, { boundBox.x, boundBox.y, 1 } };
|
||||
if (drewSupports)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_SUPPORTS].WithIndex(
|
||||
((direction & 1) ? SPR_FLOOR_PLANKS_90_DEG : SPR_FLOOR_PLANKS));
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleC[direction][trackSequence][0]);
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleC[direction][trackSequence][0]);
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1037,22 +1036,21 @@ static void PaintMiniGolfHoleD(
|
|||
break;
|
||||
}
|
||||
|
||||
auto bb = BoundBoxXYZ{ { boundBoxOffset, height }, { boundBox.x, boundBox.y, 1 } };
|
||||
auto offset = CoordsXYZ{ 0, 0, height };
|
||||
if (drewSupports)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_SUPPORTS].WithIndex(
|
||||
((supportType & 1) ? SPR_FLOOR_PLANKS_90_DEG : SPR_FLOOR_PLANKS));
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, offset, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleD[direction][trackSequence][0]);
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsChild(session, imageId, offset, bb);
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleD[direction][trackSequence][0]);
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, offset, bb);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1131,22 +1129,21 @@ static void PaintMiniGolfHoleE(
|
|||
break;
|
||||
}
|
||||
|
||||
auto bb = BoundBoxXYZ{ { boundBoxOffset, height }, { boundBox.x, boundBox.y, 1 } };
|
||||
auto offset = CoordsXYZ{ 0, 0, height };
|
||||
if (drewSupports)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_SUPPORTS].WithIndex(
|
||||
((supportType & 1) ? SPR_FLOOR_PLANKS_90_DEG : SPR_FLOOR_PLANKS));
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, offset, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleE[direction][trackSequence][0]);
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsChild(session, imageId, offset, bb);
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(MiniGolfTrackSpritesHoleE[direction][trackSequence][0]);
|
||||
PaintAddImageAsParent(
|
||||
session, imageId, { 0, 0, height }, { boundBox.x, boundBox.y, 1 }, { boundBoxOffset.x, boundBoxOffset.y, height });
|
||||
PaintAddImageAsParent(session, imageId, offset, bb);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ static void PaintMiniHelicoptersTrackStation(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 32, 28, 1 }, { 0, 2, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_TRACK_SUBMARINE_RIDE_MINI_HELICOPTERS_FLAT_NE_SW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 20, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 32, 20, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 5, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 8, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
@ -41,7 +41,7 @@ static void PaintMiniHelicoptersTrackStation(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 28, 32, 1 }, { 2, 0, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_TRACK_SUBMARINE_RIDE_MINI_HELICOPTERS_FLAT_SE_NW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 32, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 20, 32, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 6, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 7, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
|
|
@ -216,7 +216,7 @@ static void PaintMonorailCyclesStation(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 32, 28, 1 }, { 0, 2, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SprMonorailCyclesFlatSwNe);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 20, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 32, 20, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 5, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 8, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
@ -228,7 +228,7 @@ static void PaintMonorailCyclesStation(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height - 2 }, { 28, 32, 1 }, { 2, 0, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SprMonorailCyclesFlatNwSe);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 32, 1 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 0, height }, { 20, 32, 1 } });
|
||||
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 6, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
MetalASupportsPaintSetup(session, METAL_SUPPORTS_BOXED, 7, 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
|
|
@ -168,7 +168,7 @@ static void PaintObservationTowerSection(
|
|||
if (trackElement.IsLastForTile() || trackElement.GetClearanceZ() != nextTileElement->GetBaseZ())
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SprObservationTowerSegmentTop);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 2, 2, 30 }, { 8, 8, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 8, 8, height }, { 2, 2, 30 } });
|
||||
}
|
||||
|
||||
PaintUtilSetSegmentSupportHeight(session, SEGMENTS_ALL, 0xFFFF, 0);
|
||||
|
|
|
@ -74,7 +74,7 @@ static void PaintSpaceRingsStructure(
|
|||
{
|
||||
imageColourFlags = ImageId(0, rider->TshirtColour, rider->TrousersColour);
|
||||
imageId = imageColourFlags.WithIndex(baseImageId + 352 + frameNum);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 20, 20, 23 }, { -10, -10, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { -10, -10, height }, { 20, 20, 23 } });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -185,7 +185,7 @@ static void SpiralSlidePaintTileFront(
|
|||
|
||||
imageId = ImageId(offset + slide_progress, ride.slide_peep_t_shirt_colour, COLOUR_GREY);
|
||||
|
||||
PaintAddImageAsChild(session, imageId, { 16, 16, height }, boundingBox, boundingBoxOffset);
|
||||
PaintAddImageAsChild(session, imageId, { 16, 16, height }, { boundingBoxOffset, boundingBox });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -59,27 +59,27 @@ void vehicle_visual_launched_freefall(
|
|||
auto directionOffset = OpenRCT2::Entity::Yaw::YawTo4(imageDirection);
|
||||
image_id = ImageId(
|
||||
baseImage_id + (((directionOffset + 0) & 3) * 3), vehicle->peep_tshirt_colours[0], vehicle->peep_tshirt_colours[1]);
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { 16, 16, 41 }, { -5, -5, z + 1 });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { { -5, -5, z + 1 }, { 16, 16, 41 } });
|
||||
if (vehicle->num_peeps > 2)
|
||||
{
|
||||
image_id = ImageId(
|
||||
baseImage_id + (((directionOffset + 1) & 3) * 3), vehicle->peep_tshirt_colours[2],
|
||||
vehicle->peep_tshirt_colours[3]);
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { 16, 16, 41 }, { -5, -5, z + 1 });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { { -5, -5, z + 1 }, { 16, 16, 41 } });
|
||||
}
|
||||
if (vehicle->num_peeps > 4)
|
||||
{
|
||||
image_id = ImageId(
|
||||
baseImage_id + (((directionOffset + 2) & 3) * 3), vehicle->peep_tshirt_colours[4],
|
||||
vehicle->peep_tshirt_colours[5]);
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { 16, 16, 41 }, { -5, -5, z + 1 });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { { -5, -5, z + 1 }, { 16, 16, 41 } });
|
||||
}
|
||||
if (vehicle->num_peeps > 6)
|
||||
{
|
||||
image_id = ImageId(
|
||||
baseImage_id + (((directionOffset + 3) & 3) * 3), vehicle->peep_tshirt_colours[6],
|
||||
vehicle->peep_tshirt_colours[7]);
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { 16, 16, 41 }, { -5, -5, z + 1 });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { { -5, -5, z + 1 }, { 16, 16, 41 } });
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -177,7 +177,7 @@ static void paint_launched_freefall_tower_section(
|
|||
if (trackElement.IsLastForTile() || trackElement.GetClearanceZ() != nextTileElement->GetBaseZ())
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_LAUNCHED_FREEFALL_TOWER_SEGMENT_TOP);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 2, 2, 30 }, { 8, 8, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 8, 8, height }, { 2, 2, 30 } });
|
||||
}
|
||||
|
||||
PaintUtilSetSegmentSupportHeight(session, SEGMENTS_ALL, 0xFFFF, 0);
|
||||
|
|
|
@ -88,7 +88,7 @@ void vehicle_visual_roto_drop(
|
|||
baseImage_id += vehicle->restraints_position / 64;
|
||||
}
|
||||
image_id = ImageId(baseImage_id, riding_peep_sprites[i]);
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { 16, 16, 41 }, { -5, -5, z + 1 });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, { { -5, -5, z + 1 }, { 16, 16, 41 } });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -190,7 +190,7 @@ static void paint_roto_drop_tower_section(
|
|||
if (trackElement.IsLastForTile() || trackElement.GetClearanceZ() != nextTileElement->GetBaseZ())
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_ROTO_DROP_TOWER_SEGMENT_TOP);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 2, 2, 30 }, { 8, 8, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 8, 8, height }, { 2, 2, 30 } });
|
||||
}
|
||||
|
||||
PaintUtilSetSegmentSupportHeight(session, SEGMENTS_ALL, 0xFFFF, 0);
|
||||
|
|
|
@ -163,11 +163,11 @@ static void PaintSwingingInverterShip(
|
|||
break;
|
||||
case 2:
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_STATION_PLATFORM_SW_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { 32, 8, 1 }, { -2, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { { -2, 0, height }, { 32, 8, 1 } });
|
||||
break;
|
||||
case 3:
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_STATION_PLATFORM_NW_SE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { 8, 32, 1 }, { 0, -2, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { { 0, -2, height }, { 8, 32, 1 } });
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -208,7 +208,7 @@ static void PaintSwingingShip(
|
|||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(hasFence ? SPR_STATION_PLATFORM_FENCED_NW_SE : SPR_STATION_PLATFORM_NW_SE));
|
||||
}
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { 8, 32, 1 }, { 0, -2, height + 9 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { { 0, -2, height + 9 }, { 8, 32, 1 } });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(relativeTrackSequence == 2 ? SPR_STATION_PLATFORM_BEGIN_NW_SE : SPR_STATION_PLATFORM_NW_SE));
|
||||
|
@ -255,7 +255,7 @@ static void PaintSwingingShip(
|
|||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(hasFence ? SPR_STATION_PLATFORM_FENCED_SW_NE : SPR_STATION_PLATFORM_SW_NE));
|
||||
}
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { 32, 8, 1 }, { -2, 0, height + 9 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height + 9 }, { { -2, 0, height + 9 }, { 32, 8, 1 } });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(relativeTrackSequence == 2 ? SPR_STATION_PLATFORM_BEGIN_SW_NE : SPR_STATION_PLATFORM_SW_NE));
|
||||
|
|
|
@ -205,14 +205,14 @@ static void chairlift_paint_station_ne_sw(
|
|||
if (hasFence)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_FENCE_METAL_NW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 1, 7 }, { 0, 2, height + 2 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 0, 2, height + 2 }, { 32, 1, 7 } });
|
||||
}
|
||||
track_paint_util_draw_station_covers(session, EDGE_NW, hasFence, stationObj, height);
|
||||
|
||||
if ((direction == 2 && isStart) || (direction == 0 && isEnd))
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_FENCE_METAL_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 1, 28, 7 }, { 2, 2, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 2, height + 4 }, { 1, 28, 7 } });
|
||||
}
|
||||
|
||||
hasFence = track_paint_util_has_fence(EDGE_SE, pos, trackElement, ride, session.CurrentRotation);
|
||||
|
@ -235,7 +235,7 @@ static void chairlift_paint_station_ne_sw(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_CHAIRLIFT_STATION_END_CAP_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 14, 14, height + 4 }, { 4, 4, 26 } });
|
||||
|
||||
drawFrontColumn = false;
|
||||
}
|
||||
|
@ -246,7 +246,7 @@ static void chairlift_paint_station_ne_sw(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_CHAIRLIFT_STATION_END_CAP_SW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 14, 14, height + 4 }, { 4, 4, 26 } });
|
||||
|
||||
drawBackColumn = false;
|
||||
}
|
||||
|
@ -297,14 +297,14 @@ static void chairlift_paint_station_se_nw(
|
|||
if (hasFence)
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_FENCE_METAL_NE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 1, 32, 7 }, { 2, 0, height + 2 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 0, height + 2 }, { 1, 32, 7 } });
|
||||
}
|
||||
track_paint_util_draw_station_covers(session, EDGE_NE, hasFence, stationObj, height);
|
||||
|
||||
if ((direction == 1 && isStart) || (direction == 3 && isEnd))
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_FENCE_METAL_NW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 28, 1, 7 }, { 2, 2, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 2, 2, height + 4 }, { 28, 1, 7 } });
|
||||
}
|
||||
|
||||
hasFence = track_paint_util_has_fence(EDGE_SW, pos, trackElement, ride, session.CurrentRotation);
|
||||
|
@ -324,7 +324,7 @@ static void chairlift_paint_station_se_nw(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_CHAIRLIFT_STATION_END_CAP_SE);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 14, 14, height + 4 }, { 4, 4, 26 } });
|
||||
|
||||
drawLeftColumn = false;
|
||||
}
|
||||
|
@ -338,7 +338,7 @@ static void chairlift_paint_station_se_nw(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(SPR_CHAIRLIFT_STATION_END_CAP_NW);
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 4, 4, 26 }, { 14, 14, height + 4 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 14, 14, height + 4 }, { 4, 4, 26 } });
|
||||
|
||||
drawRightColumn = false;
|
||||
}
|
||||
|
|
|
@ -1006,7 +1006,7 @@ static void paint_miniature_railway_track_right_quarter_turn_5_tiles(
|
|||
CoordsXYZ boundsOffset = CoordsXYZ(offset, 0);
|
||||
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { offset, height }, { boundsLength, 2 }, boundsOffset + CoordsXYZ{ 0, 0, height });
|
||||
session, imageId, { offset, height }, { boundsOffset + CoordsXYZ{ 0, 0, height }, { boundsLength, 2 } });
|
||||
}
|
||||
}
|
||||
if (direction == 0 && trackSequence == 0)
|
||||
|
@ -1380,7 +1380,7 @@ static void paint_miniature_railway_track_right_quarter_turn_3_tiles(
|
|||
CoordsXYZ boundsOffset(offset, 0);
|
||||
|
||||
PaintAddImageAsChild(
|
||||
session, imageId, { offset, height }, { boundsLength, 3 }, boundsOffset + CoordsXYZ{ 0, 0, height });
|
||||
session, imageId, { offset, height }, { boundsOffset + CoordsXYZ{ 0, 0, height }, { boundsLength, 3 } });
|
||||
}
|
||||
track_paint_util_right_quarter_turn_3_tiles_tunnel(session, height, direction, trackSequence, TUNNEL_SQUARE_FLAT);
|
||||
|
||||
|
@ -1563,7 +1563,7 @@ static void paint_miniature_railway_track_left_eighth_to_diag(
|
|||
miniature_railway_track_pieces_left_eight_to_diag[direction][index]);
|
||||
offset = miniature_railway_track_pieces_left_eight_to_diag_offset[direction][index];
|
||||
bounds = miniature_railway_track_pieces_left_eight_to_diag_bounds[direction][index];
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bounds, { offset, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { offset, height }, bounds });
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1728,7 +1728,7 @@ static void paint_miniature_railway_track_right_eighth_to_diag(
|
|||
miniature_railway_track_pieces_right_eight_to_diag[direction][index]);
|
||||
offset = miniature_railway_track_pieces_right_eight_to_diag_offset[direction][index];
|
||||
bounds = miniature_railway_track_pieces_right_eight_to_diag_bounds[direction][index];
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bounds, { offset, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { offset, height }, bounds });
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1839,15 +1839,15 @@ static void miniature_railway_track_diag_flat(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
{
|
||||
PaintAddImageAsParent(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height }, { 32, 32, 2 } });
|
||||
}
|
||||
|
||||
PaintUtilSetSegmentSupportHeight(session, SEGMENTS_ALL, 0xFFFF, 0);
|
||||
|
@ -1940,8 +1940,8 @@ static void miniature_railway_track_diag_25_deg_up(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height + offsetB[direction] });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height + offsetB[direction] }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
|
@ -1991,15 +1991,15 @@ static void miniature_railway_track_diag_flat_to_25_deg_up(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
{
|
||||
PaintAddImageAsParent(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height }, { 32, 32, 2 } });
|
||||
}
|
||||
|
||||
PaintUtilSetSegmentSupportHeight(session, SEGMENTS_ALL, 0xFFFF, 0);
|
||||
|
@ -2067,8 +2067,8 @@ static void miniature_railway_track_diag_25_deg_up_to_flat(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height + railOffsets[direction] });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height + railOffsets[direction] }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
|
@ -2142,8 +2142,8 @@ static void miniature_railway_track_diag_25_deg_down(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height + railOffsets[direction] });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height + railOffsets[direction] }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
|
@ -2216,8 +2216,8 @@ static void miniature_railway_track_diag_flat_to_25_deg_down(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height + railOffsets[direction] });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height + railOffsets[direction] }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
|
@ -2265,8 +2265,8 @@ static void miniature_railway_track_diag_25_deg_down_to_flat(
|
|||
if (drawRail)
|
||||
{
|
||||
PaintAddImageAsChild(
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height }, { 32, 32, 2 },
|
||||
{ -16, -16, height });
|
||||
session, session.TrackColours[SCHEME_TRACK].WithIndex(imageId), { -16, -16, height },
|
||||
{ { -16, -16, height }, { 32, 32, 2 } });
|
||||
}
|
||||
}
|
||||
else if (drawRail)
|
||||
|
|
|
@ -445,11 +445,11 @@ static void paint_monorail_station(
|
|||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(monorail_track_pieces_flat[direction]);
|
||||
if (direction == 0 || direction == 2)
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { 32, 20, 2 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 6, height }, { { 0, 0, height }, { 32, 20, 2 } });
|
||||
}
|
||||
else
|
||||
{
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { 20, 32, 2 }, { 0, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 6, 0, height }, { { 0, 0, height }, { 20, 32, 2 } });
|
||||
}
|
||||
|
||||
if (direction == 0 || direction == 2)
|
||||
|
|
|
@ -223,15 +223,15 @@ void vehicle_visual_river_rapids(
|
|||
}
|
||||
baseImage_id += carEntry->base_image_id;
|
||||
|
||||
const vehicle_boundbox* bb = &_riverRapidsBoundbox[j];
|
||||
const auto& riverRapidsBb = _riverRapidsBoundbox[j];
|
||||
auto bb = BoundBoxXYZ{ { riverRapidsBb.offset_x, riverRapidsBb.offset_y, riverRapidsBb.offset_z + z },
|
||||
{ riverRapidsBb.length_x, riverRapidsBb.length_y, riverRapidsBb.length_z } };
|
||||
image_id = ImageId(baseImage_id, vehicle->colours.Body, vehicle->colours.Trim);
|
||||
if (vehicle->IsGhost())
|
||||
{
|
||||
image_id = ConstructionMarker.WithIndex(image_id.GetIndex());
|
||||
}
|
||||
PaintAddImageAsParent(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsParent(session, image_id, { 0, 0, z }, bb);
|
||||
|
||||
if (session.DPI.zoom_level < ZoomLevel{ 2 } && vehicle->num_peeps > 0 && !vehicle->IsGhost())
|
||||
{
|
||||
|
@ -239,35 +239,27 @@ void vehicle_visual_river_rapids(
|
|||
// that's how the original does it...)
|
||||
int32_t peeps = ((ecx / 8) + 0) & 3;
|
||||
image_id = ImageId(baseImage_id + ((peeps + 1) * 72), vehicle->peep_tshirt_colours[0], vehicle->peep_tshirt_colours[1]);
|
||||
PaintAddImageAsChild(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, bb);
|
||||
if (vehicle->num_peeps > 2)
|
||||
{
|
||||
peeps = ((ecx / 8) + 2) & 3;
|
||||
image_id = ImageId(
|
||||
baseImage_id + ((peeps + 1) * 72), vehicle->peep_tshirt_colours[2], vehicle->peep_tshirt_colours[3]);
|
||||
PaintAddImageAsChild(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, bb);
|
||||
}
|
||||
if (vehicle->num_peeps > 4)
|
||||
{
|
||||
peeps = ((ecx / 8) + 1) & 3;
|
||||
image_id = ImageId(
|
||||
baseImage_id + ((peeps + 1) * 72), vehicle->peep_tshirt_colours[4], vehicle->peep_tshirt_colours[5]);
|
||||
PaintAddImageAsChild(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, bb);
|
||||
}
|
||||
if (vehicle->num_peeps > 6)
|
||||
{
|
||||
peeps = ((ecx / 8) + 3) & 3;
|
||||
image_id = ImageId(
|
||||
baseImage_id + ((peeps + 1) * 72), vehicle->peep_tshirt_colours[6], vehicle->peep_tshirt_colours[7]);
|
||||
PaintAddImageAsChild(
|
||||
session, image_id, { 0, 0, z }, { bb->length_x, bb->length_y, bb->length_z },
|
||||
{ bb->offset_x, bb->offset_y, bb->offset_z + z });
|
||||
PaintAddImageAsChild(session, image_id, { 0, 0, z }, bb);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -685,7 +677,7 @@ static void paint_river_rapids_track_waterfall(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 24, 32, 11 }, { 4, 0, height });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_BASE_NE_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 24, 32, 11 }, { 4, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 4, 0, height }, { 24, 32, 11 } });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_TOP_NE_FRAME_0 + frameNum));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 1, 32, 27 }, { 4, 0, height + 17 });
|
||||
|
@ -695,26 +687,33 @@ static void paint_river_rapids_track_waterfall(
|
|||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 1, 32, 27 }, { 27, 0, height + 17 });
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_SIDE_SW_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 1, 32, 27 }, { 27, 0, height + 17 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { { 27, 0, height + 17 }, { 1, 32, 27 } });
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 0 ? SPR_RIVER_RAPIDS_WATERFALL_SW_NE : SPR_RIVER_RAPIDS_WATERFALL_NE_SW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 32, 24, 11 }, { 0, 4, height });
|
||||
|
||||
auto bb = BoundBoxXYZ{ { 0, 4, height }, { 32, 24, 11 } };
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_BASE_NW_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 24, 11 }, { 0, 4, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
bb.offset = { 0, 4, height + 17 };
|
||||
bb.length = { 32, 1, 27 };
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_TOP_NW_FRAME_0 + frameNum));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 32, 1, 27 }, { 0, 4, height + 17 });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
bb.offset = { 0, 27, height + 17 };
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 0 ? SPR_RIVER_RAPIDS_WATERFALL_FRONT_SW_NE : SPR_RIVER_RAPIDS_WATERFALL_FRONT_NE_SW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 32, 1, 27 }, { 0, 27, height + 17 });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_WATERFALL_SIDE_SE_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 1, 27 }, { 0, 27, height + 17 });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
|
||||
WoodenASupportsPaintSetup(session, (direction & 1), 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
@ -796,27 +795,37 @@ static void paint_river_rapids_track_whirlpool(
|
|||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 1 ? SPR_RIVER_RAPIDS_FLAT_NW_SE : SPR_RIVER_RAPIDS_FLAT_SE_NW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 24, 32, 11 }, { 4, 0, height });
|
||||
|
||||
auto bb = BoundBoxXYZ{ { 4, 0, height }, { 24, 32, 11 } };
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_RAPIDS_WHIRLPOOL_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 24, 32, 11 }, { 4, 0, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
bb.offset = { 10, 10, height };
|
||||
bb.length = { 1, 2, 5 };
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 1 ? SPR_RIVER_RAPIDS_FLAT_FRONT_NW_SE : SPR_RIVER_RAPIDS_FLAT_FRONT_SE_NW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 1, 2, 5 }, { 10, 10, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
else
|
||||
{
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 0 ? SPR_RIVER_RAPIDS_FLAT_SW_NE : SPR_RIVER_RAPIDS_FLAT_NE_SW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 32, 24, 11 }, { 0, 4, height });
|
||||
|
||||
auto bb = BoundBoxXYZ{ { 0, 4, height }, { 32, 24, 11 } };
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex((SPR_RIVER_RAPIDS_RAPIDS_WHIRLPOOL_FRAME_0 + frameNum));
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, { 32, 24, 11 }, { 0, 4, height });
|
||||
PaintAddImageAsChild(session, imageId, { 0, 0, height }, bb);
|
||||
|
||||
bb.offset = { 10, 10, height };
|
||||
bb.length = { 1, 2, 5 };
|
||||
|
||||
imageId = session.TrackColours[SCHEME_TRACK].WithIndex(
|
||||
(direction == 0 ? SPR_RIVER_RAPIDS_FLAT_FRONT_SW_NE : SPR_RIVER_RAPIDS_FLAT_FRONT_NE_SW));
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, { 1, 2, 5 }, { 10, 10, height });
|
||||
PaintAddImageAsParent(session, imageId, { 0, 0, height }, bb);
|
||||
}
|
||||
|
||||
WoodenASupportsPaintSetup(session, (direction & 1), 0, height, session.TrackColours[SCHEME_SUPPORTS]);
|
||||
|
|
Loading…
Reference in New Issue