mirror of https://github.com/OpenRCT2/OpenRCT2.git
18757 lines
864 KiB
C++
18757 lines
864 KiB
C++
/*****************************************************************************
|
|
* Copyright (c) 2014-2024 OpenRCT2 developers
|
|
*
|
|
* For a complete list of all authors, please refer to contributors.md
|
|
* Interested in contributing? Visit https://github.com/OpenRCT2/OpenRCT2
|
|
*
|
|
* OpenRCT2 is licensed under the GNU General Public License version 3.
|
|
*****************************************************************************/
|
|
|
|
#include "../../drawing/Drawing.h"
|
|
#include "../../interface/Viewport.h"
|
|
#include "../../paint/Paint.h"
|
|
#include "../../paint/support/MetalSupports.h"
|
|
#include "../../paint/tile_element/Paint.TileElement.h"
|
|
#include "../../paint/tile_element/Segment.h"
|
|
#include "../../paint/track/Segment.h"
|
|
#include "../../sprites.h"
|
|
#include "../../world/Map.h"
|
|
#include "../RideData.h"
|
|
#include "../TrackData.h"
|
|
#include "../TrackPaint.h"
|
|
|
|
// Closed block brakes and regular brakes use the same images
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_SW_NE_OPEN_1 = 18076;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_NW_SE_OPEN_1 = 18077;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_SW_NE_CLOSED_1 = 18078;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_NW_SE_CLOSED_1 = 18079;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_SW_NE_OPEN_2 = 18080;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_NW_SE_OPEN_2 = 18081;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_SW_NE_CLOSED_2 = 18082;
|
|
static constexpr uint32_t GIGA_COASTER_BRAKE_NW_SE_CLOSED_2 = 18083;
|
|
|
|
static constexpr uint32_t _GigaCoasterBrakeImages[NumOrthogonalDirections][2][2] = {
|
|
{ { GIGA_COASTER_BRAKE_SW_NE_OPEN_1, GIGA_COASTER_BRAKE_SW_NE_OPEN_2 },
|
|
{ GIGA_COASTER_BRAKE_SW_NE_CLOSED_1, GIGA_COASTER_BRAKE_SW_NE_CLOSED_2 } },
|
|
{ { GIGA_COASTER_BRAKE_NW_SE_OPEN_1, GIGA_COASTER_BRAKE_NW_SE_OPEN_2 },
|
|
{ GIGA_COASTER_BRAKE_NW_SE_CLOSED_1, GIGA_COASTER_BRAKE_NW_SE_CLOSED_2 } },
|
|
{ { GIGA_COASTER_BRAKE_SW_NE_OPEN_1, GIGA_COASTER_BRAKE_SW_NE_OPEN_2 },
|
|
{ GIGA_COASTER_BRAKE_SW_NE_CLOSED_1, GIGA_COASTER_BRAKE_SW_NE_CLOSED_2 } },
|
|
{ { GIGA_COASTER_BRAKE_NW_SE_OPEN_1, GIGA_COASTER_BRAKE_NW_SE_OPEN_2 },
|
|
{ GIGA_COASTER_BRAKE_NW_SE_CLOSED_1, GIGA_COASTER_BRAKE_NW_SE_CLOSED_2 } },
|
|
};
|
|
|
|
/* first level : open, closed
|
|
* second level: background, foreground
|
|
* third level: direction
|
|
*/
|
|
static constexpr uint32_t GigaDiagBrakeImages[2][2][NumOrthogonalDirections] = {
|
|
{
|
|
// Open
|
|
{
|
|
// Background
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 3,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 3,
|
|
},
|
|
{
|
|
// Foreground
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 2,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 4,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 2,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 4,
|
|
},
|
|
},
|
|
{
|
|
// Closed
|
|
{
|
|
// Background
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 1,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 3,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 1,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 3,
|
|
},
|
|
{
|
|
// Foreground
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 2,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 5,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 2,
|
|
SPR_G2_GIGA_RC_DIAG_BRAKES + 5,
|
|
},
|
|
},
|
|
};
|
|
|
|
/** rct2: 0x008AD674 */
|
|
static void GigaRCTrackFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18692), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18693), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
}
|
|
else if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18382), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18383), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18384), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18385), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18074), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18075), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrackStation(
|
|
PaintSession& session, const Ride& ride, [[maybe_unused]] uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
static constexpr uint32_t imageIds[4][2] = {
|
|
{ 18084, SPR_STATION_BASE_A_SW_NE },
|
|
{ 18085, SPR_STATION_BASE_A_NW_SE },
|
|
{ 18084, SPR_STATION_BASE_A_SW_NE },
|
|
{ 18085, SPR_STATION_BASE_A_NW_SE },
|
|
};
|
|
|
|
if (trackElement.GetTrackType() == TrackElemType::EndStation)
|
|
{
|
|
bool isClosed = trackElement.IsBrakeClosed();
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(_GigaCoasterBrakeImages[direction][isClosed][0]),
|
|
{ 0, 0, height }, { { 0, 6, height + 3 }, { 32, 20, 1 } });
|
|
}
|
|
else
|
|
{
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(imageIds[direction][0]), { 0, 0, height },
|
|
{ { 0, 6, height + 3 }, { 32, 20, 1 } });
|
|
}
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, GetStationColourScheme(session, trackElement).WithIndex(imageIds[direction][1]), { 0, 0, height },
|
|
{ 32, 32, 1 });
|
|
DrawSupportsSideBySide(session, direction, height, session.SupportColours, MetalSupportType::Tubes);
|
|
TrackPaintUtilDrawStation2(session, ride, direction, height, trackElement, 9, 11);
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD684 */
|
|
static void GigaRCTrack25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18702), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18703), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18704), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18705), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
}
|
|
else if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18394), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18395), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18396), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18397), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18134), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18135), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18136), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18137), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD694 */
|
|
static void GigaRCTrack60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18718), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18719), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18720), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18721), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 32, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18150), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18151), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18152), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18153), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 32, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 56, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD6A4 */
|
|
static void GigaRCTrackFlatTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18694), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18695), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18696), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18697), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
}
|
|
else if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18386), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18387), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18388), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18389), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18126), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18127), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18128), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18129), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD6B4 */
|
|
static void GigaRCTrack25DegUpTo60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18706), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18707), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18710), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18708), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18711), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18709), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18138), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18139), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18142), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18140), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18143), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18141), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 24, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD6C4 */
|
|
static void GigaRCTrack60DegUpTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18712), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18713), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18716), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18714), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18717), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18715), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 20, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18144), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18145), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18148), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18146), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18149), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18147), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 20, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 24, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD6D4 */
|
|
static void GigaRCTrack25DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18698), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18699), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18700), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18701), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
}
|
|
else if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18390), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18391), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18392), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18393), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18130), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18131), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18132), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18133), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD6E4 */
|
|
static void GigaRCTrack25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD6F4 */
|
|
static void GigaRCTrack60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack60DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD704 */
|
|
static void GigaRCTrackFlatTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpToFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD714 */
|
|
static void GigaRCTrack25DegDownTo60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack60DegUpTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD724 */
|
|
static void GigaRCTrack60DegDownTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpTo60DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD734 */
|
|
static void GigaRCTrack25DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackFlatTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD744 */
|
|
static void GigaRCTrackLeftQuarterTurn5(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18189), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18194), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18199), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18184), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18188), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18193), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18198), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18183), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18187), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18192), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18197), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18182), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18186), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18191), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18196), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18181), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18185), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18190), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18195), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18180), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD754 */
|
|
static void GigaRCTrackRightQuarterTurn5(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackLeftQuarterTurn5(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD764 */
|
|
static void GigaRCTrackFlatToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18086), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18094), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18087), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18095), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18088), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18089), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD774 */
|
|
static void GigaRCTrackFlatToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18090), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18091), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18092), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18096), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18093), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18097), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD784 */
|
|
static void GigaRCTrackLeftBankToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18092), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18096), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18093), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18097), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18090), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18091), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD794 */
|
|
static void GigaRCTrackRightBankToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18088), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18089), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18086), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18094), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18087), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18095), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD7A4 */
|
|
static void GigaRCTrackBankedLeftQuarterTurn5(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18209), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18220), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18214), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18219), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18204), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18208), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18213), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 32, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18218), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18203), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18207), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18212), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18217), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18202), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18206), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18211), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18216), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18201), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18205), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18210), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18215), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18221), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18200), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD7B4 */
|
|
static void GigaRCTrackBankedRightQuarterTurn5(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackBankedLeftQuarterTurn5(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD7C4 */
|
|
static void GigaRCTrackLeftBankTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18098), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18102), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18099), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18103), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18100), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18101), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD7D4 */
|
|
static void GigaRCTrackRightBankTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18104), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18105), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18106), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18108), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18107), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18109), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD7E4 */
|
|
static void GigaRCTrack25DegUpToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18110), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18114), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18111), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18115), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18112), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18113), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD7F4 */
|
|
static void GigaRCTrack25DegUpToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18116), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18117), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18118), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18120), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18119), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18121), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD804 */
|
|
static void GigaRCTrackLeftBankTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpToRightBank(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD814 */
|
|
static void GigaRCTrackRightBankTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpToLeftBank(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD824 */
|
|
static void GigaRCTrack25DegDownToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBankTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD834 */
|
|
static void GigaRCTrack25DegDownToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBankTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD844 */
|
|
static void GigaRCTrackLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18122), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18123), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18124), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18125), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD854 */
|
|
static void GigaRCTrackRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBank(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD864 */
|
|
static void GigaRCTrackLeftQuarterTurn525DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18274), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18279), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18284), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18289), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18275), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18280), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18285), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18290), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18276), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18281), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18286), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18291), { 0, 0, height }, { 16, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18277), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18282), { 0, 0, height }, { 16, 32, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18287), { 0, 0, height }, { 16, 32, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18292), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18278), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18283), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18288), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18293), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD874 */
|
|
static void GigaRCTrackRightQuarterTurn525DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18254), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18259), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18264), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18269), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18255), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18260), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18265), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18270), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18256), { 0, 0, height }, { 16, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18261), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18266), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18271), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18257), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18262), { 0, 0, height }, { 16, 32, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18267), { 0, 0, height }, { 16, 32, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18272), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18258), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18263), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18268), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18273), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD884 */
|
|
static void GigaRCTrackLeftQuarterTurn525DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackRightQuarterTurn525DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD894 */
|
|
static void GigaRCTrackRightQuarterTurn525DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackLeftQuarterTurn525DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD8A4 */
|
|
static void GigaRCTrackSBendLeft(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18238), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18242), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18241), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18245), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18239), { 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18243), { 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 1, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18240), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18244), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18240), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18244), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18239), { 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18243), { 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 1, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18241), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18245), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18238), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18242), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD8B4 */
|
|
static void GigaRCTrackSBendRight(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18246), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18250), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18249), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18253), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18247), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18251), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18248), { 0, 0, height }, { 32, 26, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18252), { 0, 0, height }, { 32, 26, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18248), { 0, 0, height }, { 32, 26, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18252), { 0, 0, height }, { 32, 26, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18247), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18251), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 26, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18249), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18253), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18246), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18250), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD8F4 */
|
|
static void GigaRCTrackLeftQuarterTurn3(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18159), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18162), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18165), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18156), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18158), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18161), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18164), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18155), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18157), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18160), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18163), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18154), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD904 */
|
|
static void GigaRCTrackRightQuarterTurn3(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackLeftQuarterTurn3(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD914 */
|
|
static void GigaRCTrackLeftQuarterTurn3Bank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18171), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18178), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18174), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18177), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18168), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18170), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18173), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18176), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18167), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18169), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18172), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18175), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18179), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18166), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD924 */
|
|
static void GigaRCTrackRightQuarterTurn3Bank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackLeftQuarterTurn3Bank(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD934 */
|
|
static void GigaRCTrackLeftQuarterTurn325DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18305), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18307), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18309), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18303), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18304), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18306), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18308), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18302), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD944 */
|
|
static void GigaRCTrackRightQuarterTurn325DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18294), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18296), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18298), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18300), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18295), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18297), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18299), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 10, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18301), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD954 */
|
|
static void GigaRCTrackLeftQuarterTurn325DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackRightQuarterTurn325DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD964 */
|
|
static void GigaRCTrackRightQuarterTurn325DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackLeftQuarterTurn325DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD974 */
|
|
static void GigaRCTrackLeftHalfBankedHelixUpSmall(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18329), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18336), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18332), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18335), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18326), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 2, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18328), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18331), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18334), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18325), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18327), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18330), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18333), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18337), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18324), { 0, 0, height },
|
|
{ { 6, 0, height + 8 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18326), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18329), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18336), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18332), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18335), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 2, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18325), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18328), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18331), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18334), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18324), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18327), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18330), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18333), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18337), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD984 */
|
|
static void GigaRCTrackRightHalfBankedHelixUpSmall(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18310), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18313), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18316), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18319), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18323), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 2, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18311), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18314), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18317), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18320), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18312), { 0, 0, height },
|
|
{ { 6, 0, height + 8 }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18315), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18322), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18318), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18321), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18313), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18316), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18319), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18323), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18310), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 2, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18314), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18317), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18320), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18311), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18315), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18322), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18318), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18321), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18312), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD994 */
|
|
static void GigaRCTrackLeftHalfBankedHelixDownSmall(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackSequence >= 4)
|
|
{
|
|
trackSequence -= 4;
|
|
direction = (direction - 1) & 3;
|
|
}
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackRightHalfBankedHelixUpSmall(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD9A4 */
|
|
static void GigaRCTrackRightHalfBankedHelixDownSmall(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackSequence >= 4)
|
|
{
|
|
trackSequence -= 4;
|
|
direction = (direction + 1) & 3;
|
|
}
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackLeftHalfBankedHelixUpSmall(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD9B4 */
|
|
static void GigaRCTrackLeftHalfBankedHelixUpLarge(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18369), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18380), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18374), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18379), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18364), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18368), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18373), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 32, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18378), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18363), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18367), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18372), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18377), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18362), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18366), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18371), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18376), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18361), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18365), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18370), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18375), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18381), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18360), { 0, 0, height },
|
|
{ { 6, 0, height + 8 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18364), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18369), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18380), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18374), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18379), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 8:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 9:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18363), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18368), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18373), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 32, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18378), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 10:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18362), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18367), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18372), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18377), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 11:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 12:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18361), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18366), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18371), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 32, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18376), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 13:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18360), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18365), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18370), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18375), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18381), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD9C4 */
|
|
static void GigaRCTrackRightHalfBankedHelixUpLarge(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18338), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18343), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18348), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18353), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18359), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18339), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18344), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18349), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 32, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18354), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18340), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18345), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18350), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18355), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18341), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18346), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18351), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 32, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18356), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18342), { 0, 0, height },
|
|
{ { 6, 0, height + 8 }, { 20, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18347), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18358), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18352), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18357), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18343), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18348), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18353), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18359), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18338), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 8:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 9:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18344), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18349), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 16, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18354), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18339), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 10:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18345), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18350), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18355), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18340), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 11:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 12:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18346), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18351), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 32, 16, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18356), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18341), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 13:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18347), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18358), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18352), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18357), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18342), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008AD9D4 */
|
|
static void GigaRCTrackLeftHalfBankedHelixDownLarge(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackSequence >= 7)
|
|
{
|
|
trackSequence -= 7;
|
|
direction = (direction - 1) & 3;
|
|
}
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackRightHalfBankedHelixUpLarge(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008AD9E4 */
|
|
static void GigaRCTrackRightHalfBankedHelixDownLarge(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
if (trackSequence >= 7)
|
|
{
|
|
trackSequence -= 7;
|
|
direction = (direction + 1) & 3;
|
|
}
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackLeftHalfBankedHelixUpLarge(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADA14 */
|
|
static void GigaRCTrackLeftQuarterTurn160DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18231), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18235), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18232), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18236), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18233), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18237), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18230), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18234), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
}
|
|
TrackPaintUtilLeftQuarterTurn1TileTunnel(session, direction, height, -8, TUNNEL_SQUARE_7, +56, TUNNEL_SQUARE_8);
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008AD9F4 */
|
|
static void GigaRCTrackRightQuarterTurn160DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18222), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18226), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18223), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18227), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18224), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18228), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18225), { 0, 0, height },
|
|
{ { 2, 2, height }, { 28, 28, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18229), { 0, 0, height },
|
|
{ { 2, 2, height + 99 }, { 28, 28, 1 } });
|
|
break;
|
|
}
|
|
TrackPaintUtilRightQuarterTurn1TileTunnel(session, direction, height, -8, TUNNEL_SQUARE_7, +56, TUNNEL_SQUARE_8);
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADA04 */
|
|
static void GigaRCTrackLeftQuarterTurn160DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightQuarterTurn160DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADA24 */
|
|
static void GigaRCTrackRightQuarterTurn160DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftQuarterTurn160DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADA34 */
|
|
static void GigaRCTrackBrakes(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(GIGA_COASTER_BRAKE_SW_NE_CLOSED_1), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(GIGA_COASTER_BRAKE_SW_NE_CLOSED_2), { 0, 0, height },
|
|
{ { 0, 27, height + 5 }, { 32, 1, 11 } });
|
|
break;
|
|
case 1:
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(GIGA_COASTER_BRAKE_NW_SE_CLOSED_1), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(GIGA_COASTER_BRAKE_NW_SE_CLOSED_2), { 0, 0, height },
|
|
{ { 0, 27, height + 5 }, { 32, 1, 11 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADC84 */
|
|
static void GigaRCTrack25DegUpLeftBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18560), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18561), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18562), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18563), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADC94 */
|
|
static void GigaRCTrack25DegUpRightBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18564), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18565), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18566), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18567), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADA44 */
|
|
static void GigaRCTrackOnRidePhoto(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
TrackPaintUtilOnridePhotoPlatformPaint(session, direction, height, MetalSupportType::Tubes);
|
|
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18074), { 0, 0, height },
|
|
{ { 0, 6, height + 3 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18075), { 0, 0, height },
|
|
{ { 0, 6, height + 3 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18074), { 0, 0, height },
|
|
{ { 0, 6, height + 3 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18075), { 0, 0, height },
|
|
{ { 0, 6, height + 3 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
TrackPaintUtilOnridePhotoPaint(session, direction, height + 3, trackElement);
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADCA4 */
|
|
static void GigaRCTrack25DegDownLeftBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpRightBanked(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADCB4 */
|
|
static void GigaRCTrack25DegDownRightBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpLeftBanked(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADED4 */
|
|
static void GigaRCTrackFlatTo60DegUpLongBase(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18722), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18726), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18730), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18734), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18660), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18664), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18668), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18672), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18723), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18727), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18731), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18735), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18661), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18665), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18669), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18673), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18724), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18728), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18732), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18736), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18662), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18666), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18670), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18674), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasCableLift())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18725), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18729), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18733), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18737), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18663), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18667), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18671), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18675), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
}
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 24, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 24, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 80, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADEE4 */
|
|
static void GigaRCTrack60DegUpToFlatLongBase(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18676), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18680), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18684), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18688), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 16, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 80, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18677), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18681), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18685), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18689), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 80, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18678), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18682), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18686), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18690), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 9, height, session.SupportColours);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18679), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18683), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18687), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18691), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_FLAT);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADEF4 */
|
|
static void GigaRCTrack60DegDownToFlatLongBase(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackFlatTo60DegUpLongBase(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADF04 */
|
|
static void GigaRCTrackFlatTo60DegDownLongBase(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack60DegUpToFlatLongBase(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADF14 */
|
|
static void GigaRCTrackCableLiftHill(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18698), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18699), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18700), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18701), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18700), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18701), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18698), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18699), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18714), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18717), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18715), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18712), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18713), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18716), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 66 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 20, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 24, TUNNEL_SQUARE_8);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18720), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18721), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18718), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18719), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 98 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 32, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 56, TUNNEL_SQUARE_8);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADA64 */
|
|
static void GigaRCTrackLeftEighthToDiag(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18414), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18418), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18422), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18426), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18415), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18419), { 0, 0, height },
|
|
{ { 0, 0, height }, { 34, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18423), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18427), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18416), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18420), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18424), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18428), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18417), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18421), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18425), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18429), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADA74 */
|
|
static void GigaRCTrackRightEighthToDiag(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18398), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18402), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18406), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18410), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18399), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18403), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18407), { 0, 0, height },
|
|
{ { 0, 0, height }, { 34, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18411), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18400), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18404), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18408), { 0, 0, height },
|
|
{ { 4, 4, height }, { 28, 28, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18412), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18401), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18405), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18409), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18413), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADA84 */
|
|
static void GigaRCTrackLeftEighthToOrthogonal(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackRightEighthToDiag(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADA94 */
|
|
static void GigaRCTrackRightEighthToOrthogonal(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackLeftEighthToDiag(session, ride, trackSequence, (direction + 3) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADAA4 */
|
|
static void GigaRCTrackLeftEighthBankToDiag(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18446), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18450), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18454), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18458), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18447), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18451), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 34, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18455), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18459), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18448), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18452), { 0, 0, height },
|
|
{ { 16, 16, height + 27 }, { 16, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18456), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18460), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18449), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18453), { 0, 0, height },
|
|
{ { 0, 16, height + 27 }, { 16, 18, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18457), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18461), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADAB4 */
|
|
static void GigaRCTrackRightEighthBankToDiag(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18430), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18434), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18438), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18442), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18431), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18435), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18439), { 0, 0, height },
|
|
{ { 0, 0, height + 27 }, { 34, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18443), { 0, 0, height },
|
|
{ { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18432), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18436), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18440), { 0, 0, height },
|
|
{ { 4, 4, height + 27 }, { 28, 28, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18444), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18433), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18437), { 0, 0, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18441), { 0, 0, height },
|
|
{ { 0, 16, height + 27 }, { 16, 18, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18445), { 0, 0, height },
|
|
{ { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADAC4 */
|
|
static void GigaRCTrackLeftEighthBankToOrthogonal(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackRightEighthBankToDiag(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADAD4 */
|
|
static void GigaRCTrackRightEighthBankToOrthogonal(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackLeftEighthBankToDiag(session, ride, trackSequence, (direction + 3) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADA54 */
|
|
static void GigaRCTrackDiagFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18527), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18465), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18524), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18462), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18526), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18464), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18525), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18463), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kDiagStraightFlat[trackSequence], direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADB04 */
|
|
static void GigaRCTrackDiag25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18539), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18477), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18536), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18474), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18538), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18476), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18537), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18475), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB64 */
|
|
static void GigaRCTrackDiag60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18489), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18486), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18488), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 32, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18487), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 36, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 32, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 36, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADAE4 */
|
|
static void GigaRCTrackDiagFlatTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18531), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18469), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18528), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18466), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18530), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18468), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18529), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18467), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB44 */
|
|
static void GigaRCTrackDiag25DegUpTo60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18481), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18478), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18480), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 16, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18479), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 16, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 16, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 16, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB54 */
|
|
static void GigaRCTrackDiag60DegUpTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18485), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18482), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18484), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 21, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18483), { -16, -16, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 21, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 21, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 21, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADAF4 */
|
|
static void GigaRCTrackDiag25DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18535), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18473), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18532), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18470), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18534), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18472), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18533), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18471), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB34 */
|
|
static void GigaRCTrackDiag25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18537), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18475), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18538), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18476), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18536), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18474), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18539), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18477), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB94 */
|
|
static void GigaRCTrackDiag60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18487), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18488), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18486), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 24, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18489), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 28, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 24, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 28, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 104, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB14 */
|
|
static void GigaRCTrackDiagFlatTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18533), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18471), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18534), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18472), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18532), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18470), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18535), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18473), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADB74 */
|
|
static void GigaRCTrackDiag25DegDownTo60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18483), { -16, -16, height },
|
|
{ { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18484), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18482), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 17, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18485), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 17, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 17, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 17, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB84 */
|
|
static void GigaRCTrackDiag60DegDownTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18479), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18480), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18478), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18481), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADB24 */
|
|
static void GigaRCTrackDiag25DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18529), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18467), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18530), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18468), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18528), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18466), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
if (trackElement.HasChain())
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18531), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18469), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBC4 */
|
|
static void GigaRCTrackDiagFlatToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18497), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18494), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18498), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18496), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18495), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBD4 */
|
|
static void GigaRCTrackDiagFlatToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18502), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18499), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18501), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18503), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18500), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBE4 */
|
|
static void GigaRCTrackDiagLeftBankToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18500), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18501), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18503), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18499), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18502), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBF4 */
|
|
static void GigaRCTrackDiagRightBankToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18495), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18496), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18494), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18498), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18497), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC24 */
|
|
static void GigaRCTrackDiagLeftBankTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18517), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18514), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18518), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18516), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18515), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC34 */
|
|
static void GigaRCTrackDiagRightBankTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18522), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18519), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18521), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18523), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18520), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC04 */
|
|
static void GigaRCTrackDiag25DegUpToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18507), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18504), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18508), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18506), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18505), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC14 */
|
|
static void GigaRCTrackDiag25DegUpToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18512), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18509), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18511), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18513), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18510), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC44 */
|
|
static void GigaRCTrackDiagLeftBankTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18510), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18511), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18513), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18509), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18512), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADC54 */
|
|
static void GigaRCTrackDiagRightBankTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18505), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18506), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18504), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18508), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18507), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADC64 */
|
|
static void GigaRCTrackDiag25DegDownToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18520), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18521), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18523), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18519), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18522), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADC74 */
|
|
static void GigaRCTrackDiag25DegDownToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18515), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18516), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18514), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18518), { -16, -16, height },
|
|
{ { -16, -16, height + 35 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18517), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBA4 */
|
|
static void GigaRCTrackDiagLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18493), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18490), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18492), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18491), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADBB4 */
|
|
static void GigaRCTrackDiagRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18491), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18492), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18490), { -16, -16, height },
|
|
{ { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18493), { -16, -16, height },
|
|
{ { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADEC4 */
|
|
static void GigaRCTrackBlockBrakes(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
bool isClosed = trackElement.IsBrakeClosed();
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(_GigaCoasterBrakeImages[direction][isClosed][0]), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(_GigaCoasterBrakeImages[direction][isClosed][1]), { 0, 0, height },
|
|
{ { 0, 27, height + 5 }, { 32, 1, 11 } });
|
|
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADCC4 */
|
|
static void GigaRCTrackLeftBankedQuarterTurn325DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18655), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18657), { 0, 6, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18659), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18653), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18654), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18656), { 6, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18658), { 6, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18652), { 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADCD4 */
|
|
static void GigaRCTrackRightBankedQuarterTurn325DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18644), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18646), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18648), { 0, 6, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18650), { 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18645), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18647), { 6, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18649), { 6, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 10, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18651), { 6, 0, height }, { 20, 32, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADCE4 */
|
|
static void GigaRCTrackLeftBankedQuarterTurn325DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackRightBankedQuarterTurn325DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADCF4 */
|
|
static void GigaRCTrackRightBankedQuarterTurn325DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn3TilesToRightQuarterTurn3Tiles[trackSequence];
|
|
GigaRCTrackLeftBankedQuarterTurn325DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADD04 */
|
|
static void GigaRCTrackLeftBankedQuarterTurn525DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18624), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18629), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18634), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18639), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18625), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18630), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18635), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18640), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18626), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18631), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18636), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18641), { 0, 0, height }, { 16, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18627), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18632), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18637), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18642), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18628), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18633), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18638), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18643), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADD14 */
|
|
static void GigaRCTrackRightBankedQuarterTurn525DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18604), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18609), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18614), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18619), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18605), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18610), { 0, 0, height },
|
|
{ { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18615), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18620), { 0, 0, height }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18606), { 0, 0, height }, { 16, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18611), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18616), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18621), { 0, 0, height },
|
|
{ { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18607), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18612), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18617), { 0, 0, height },
|
|
{ { 30, 30, height }, { 1, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18622), { 0, 0, height },
|
|
{ { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18608), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18613), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18618), { 0, 0, height },
|
|
{ { 27, 0, height }, { 1, 32, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18623), { 0, 0, height },
|
|
{ { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_SQUARE_8);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
/** rct2: 0x008ADD24 */
|
|
static void GigaRCTrackLeftBankedQuarterTurn525DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackRightBankedQuarterTurn525DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADD34 */
|
|
static void GigaRCTrackRightBankedQuarterTurn525DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftQuarterTurn5TilesToRightQuarterTurn5Tiles[trackSequence];
|
|
GigaRCTrackLeftBankedQuarterTurn525DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADD44 */
|
|
static void GigaRCTrack25DegUpToLeftBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18568), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18569), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18576), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18570), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18571), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADD54 */
|
|
static void GigaRCTrack25DegUpToRightBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18572), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18573), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18574), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18577), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18575), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADD64 */
|
|
static void GigaRCTrackLeftBanked25DegUpTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18578), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18579), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18586), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18580), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18581), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADD74 */
|
|
static void GigaRCTrackRightBanked25DegUpTo25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18582), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18583), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18584), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18587), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18585), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADD84 */
|
|
static void GigaRCTrack25DegDownToLeftBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBanked25DegUpTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADD94 */
|
|
static void GigaRCTrack25DegDownToRightBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBanked25DegUpTo25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADDA4 */
|
|
static void GigaRCTrackLeftBanked25DegDownTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpToRightBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADDB4 */
|
|
static void GigaRCTrackRightBanked25DegDownTo25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack25DegUpToLeftBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADDC4 */
|
|
static void GigaRCTrackLeftBankedFlatToLeftBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18588), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18589), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18590), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18591), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADDD4 */
|
|
static void GigaRCTrackRightBankedFlatToRightBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18592), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18593), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18594), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18595), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE04 */
|
|
static void GigaRCTrackLeftBanked25DegUpToLeftBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18596), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18597), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18598), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18599), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE14 */
|
|
static void GigaRCTrackRightBanked25DegUpToRightBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18600), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18601), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18602), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18603), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE24 */
|
|
static void GigaRCTrackLeftBankedFlatToLeftBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBanked25DegUpToRightBankedFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADE34 */
|
|
static void GigaRCTrackRightBankedFlatToRightBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBanked25DegUpToLeftBankedFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADDE4 */
|
|
static void GigaRCTrackLeftBanked25DegDownToLeftBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBankedFlatToRightBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADDF4 */
|
|
static void GigaRCTrackRightBanked25DegDownToRightBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBankedFlatToLeftBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADE44 */
|
|
static void GigaRCTrackFlatToLeftBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18540), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18541), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18548), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18542), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18543), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE54 */
|
|
static void GigaRCTrackFlatToRightBanked25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18544), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18545), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18546), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18549), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18547), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE64 */
|
|
static void GigaRCTrackLeftBanked25DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18550), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18551), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18558), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18552), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18553), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE74 */
|
|
static void GigaRCTrackRightBanked25DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18554), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18555), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18556), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18559), { 0, 0, height },
|
|
{ { 0, 27, height }, { 32, 1, 34 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(18557), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_FLAT);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_14);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
}
|
|
|
|
/** rct2: 0x008ADE84 */
|
|
static void GigaRCTrackFlatToLeftBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBanked25DegUpToFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADE94 */
|
|
static void GigaRCTrackFlatToRightBanked25DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBanked25DegUpToFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADEA4 */
|
|
static void GigaRCTrackLeftBanked25DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackFlatToRightBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
/** rct2: 0x008ADEB4 */
|
|
static void GigaRCTrackRightBanked25DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackFlatToLeftBanked25DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackBooster(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_RC_BOOSTER_NE_SW), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_RC_BOOSTER_NW_SE), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
}
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_SQUARE_FLAT);
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrackPoweredLift(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_RC_POWERED_LIFT_0 + direction), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_SQUARE_7);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_SQUARE_8);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrack90DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 8)), { 0, 0, height },
|
|
{ { 4, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 9)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 10)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 11)), { 0, 0, height },
|
|
{ { 4, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
}
|
|
PaintUtilSetVerticalTunnel(session, height + 32);
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrack90DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack90DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrack60DegUpTo90DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 0)), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 1)), { 0, 0, height },
|
|
{ { 24, 6, height }, { 2, 20, 55 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 2)), { 0, 0, height },
|
|
{ { 24, 6, height }, { 2, 20, 55 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 3)), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (TrackPaintUtilShouldPaintSupports(session.MapPosition))
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 36, height, session.SupportColours);
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetVerticalTunnel(session, height + 56);
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrack90DegDownTo60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack60DegUpTo90DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrack90DegUpTo60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 4)), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 5)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 6)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 7)), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 48, TUNNEL_2);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 48, TUNNEL_2);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 80, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrack60DegDownTo90DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 6)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 7)), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 4)), { 0, 0, height },
|
|
{ { 0, 6, height + 8 }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL + 5)), { 0, 0, height },
|
|
{ { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 48, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 80, 0x20);
|
|
break;
|
|
case 1:
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftQuarterTurn190DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 0)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 1)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 2)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 3)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 4)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 5)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
}
|
|
PaintUtilSetVerticalTunnel(session, height + 96);
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 96, 0x20);
|
|
break;
|
|
case 1:
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightQuarterTurn190DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 6)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 7)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 8)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 9)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 10)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_VERTICAL_TWIST + 11)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 96 } });
|
|
break;
|
|
}
|
|
PaintUtilSetVerticalTunnel(session, height + 96);
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 96, 0x20);
|
|
break;
|
|
case 1:
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftQuarterTurn190DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightQuarterTurn190DegUp(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightQuarterTurn190DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftQuarterTurn190DegUp(session, ride, trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftBarrelRollUpToDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height - 2,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 6)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 7)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height - 2,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 12)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 13)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height + 1, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 18)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 19)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height + 1, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 2)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 3)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 8)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 9)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 14)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 4)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 5)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 10)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 11)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 17)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 22)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 23)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_INVERTED_3);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_INVERTED_3);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightBarrelRollUpToDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 24)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 25)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 0, height + 1, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 30)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 31)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height + 1,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 36)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 37)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height - 2,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 42)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 43)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height - 2, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 26)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 27)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 32)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 33)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 38)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 39)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 44)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 45)),
|
|
{ 0, 0, height }, { { 0, 6, height + 28 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 28)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 29)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 34)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 40)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 41)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 46)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_BARREL_ROLL + 47)),
|
|
{ 0, 0, height }, { { 0, 6, height + 44 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_INVERTED_3);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_INVERTED_3);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftBarrelRollDownToUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftBarrelRollUpToDown(session, ride, 2 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightBarrelRollDownToUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightBarrelRollUpToDown(session, ride, 2 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackHalfLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 0)), { 0, 6, height },
|
|
{ 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 4)), { 0, 6, height },
|
|
{ 32, 20, 11 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 8)), { 0, 6, height },
|
|
{ 32, 20, 9 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 12)),
|
|
{ 0, 6, height }, { 32, 20, 7 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 1)), { 0, 0, height },
|
|
{ { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 20, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 5)),
|
|
{ 0, 14, height }, { { 28, 6, height }, { 3, 20, 63 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 15, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 9)), { 0, 6, height },
|
|
{ { 28, 6, height }, { 3, 20, 63 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 16, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 13)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 16, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 2)),
|
|
{ 16, 0, height }, { 2, 16, 119 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 6)),
|
|
{ 12, 0, height }, { { 12, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 10)),
|
|
{ 10, 16, height }, { 4, 12, 119 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 14)),
|
|
{ 16, 16, height }, { { 15, 6, height }, { 2, 16, 119 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 168, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 3)),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 7)),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 11)),
|
|
{ 0, 16, height + 32 }, { 32, 12, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_HALF_LOOP + 15)),
|
|
{ 0, 16, height + 32 }, { 32, 12, 3 });
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackHalfLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackHalfLoopUp(session, ride, 3 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftVerticalLoop(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 0),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 4),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 8),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 12),
|
|
{ 0, 6, height }, { 32, 20, 7 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 1),
|
|
{ 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 26, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 5),
|
|
{ 0, 14, height }, { 32, 2, 63 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 10, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 9),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 14, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 13),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 2),
|
|
{ 16, 0, height }, { { 16, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 6),
|
|
{ 12, 0, height }, { { 12, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 10),
|
|
{ 10, 16, height }, { { 10, 16, height }, { 4, 16, 119 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 14),
|
|
{ 16, 16, height }, { { 16, 16, height }, { 2, 16, 119 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 168, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 3),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 7),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 11),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 15),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 5:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 11),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 15),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 3),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 7),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 10),
|
|
{ 10, 16, height }, { { 10, 16, height }, { 4, 16, 119 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 14),
|
|
{ 16, 16, height }, { { 16, 16, height }, { 2, 16, 119 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 2),
|
|
{ 16, 0, height }, { { 16, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 6),
|
|
{ 12, 0, height }, { { 12, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 168, 0x20);
|
|
break;
|
|
case 8:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 9),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 14, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 13),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 1),
|
|
{ 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 26, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 5),
|
|
{ 0, 14, height }, { 32, 2, 63 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 10, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 9:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 8),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 12),
|
|
{ 0, 6, height }, { 32, 20, 7 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 0),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 4),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height - 8, TUNNEL_1);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height - 8, TUNNEL_1);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightVerticalLoop(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 16),
|
|
{ 0, 6, height }, { 32, 20, 7 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 20),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 24),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 28),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 17),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 21),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 14, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 25),
|
|
{ 0, 14, height }, { 32, 2, 63 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 10, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 29),
|
|
{ 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 26, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 18),
|
|
{ 16, 16, height }, { { 16, 16, height }, { 2, 16, 119 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 22),
|
|
{ 10, 16, height }, { { 10, 16, height }, { 4, 16, 119 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 26),
|
|
{ 12, 0, height }, { { 12, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 30),
|
|
{ 16, 0, height }, { { 16, 0, height }, { 2, 16, 119 } });
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 168, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 19),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 23),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 27),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 31),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 5:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 27),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 31),
|
|
{ 0, 0, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 19),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 23),
|
|
{ 0, 16, height + 32 }, { 32, 16, 3 });
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 7:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 26),
|
|
{ 12, 0, height }, { { 12, 0, height }, { 3, 16, 119 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 30),
|
|
{ 16, 0, height }, { { 16, 0, height }, { 2, 16, 119 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 18),
|
|
{ 16, 16, height }, { { 16, 16, height }, { 2, 16, 119 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 22),
|
|
{ 10, 16, height }, { { 10, 16, height }, { 4, 16, 119 } });
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 168, 0x20);
|
|
break;
|
|
case 8:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 25),
|
|
{ 0, 14, height }, { 32, 2, 63 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 10, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 29),
|
|
{ 0, 0, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 26, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 17),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 21),
|
|
{ 0, 6, height }, { 32, 26, 3 });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 14, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 9:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 24),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 28),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 16),
|
|
{ 0, 6, height }, { 32, 20, 7 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex(SPR_G2_GIGA_TRACK_VERTICAL_LOOP + 20),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height - 8, TUNNEL_1);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height - 8, TUNNEL_1);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
|
|
TrackPaintUtilRightVerticalLoopSegments(session, direction, trackSequence);
|
|
}
|
|
|
|
static void GigaRCTrackLeftCorkscrewUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 0)), { 0, 0, height },
|
|
{ { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height - 3, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 3)), { 0, 0, height },
|
|
{ { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 6)), { 0, 0, height },
|
|
{ { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 9)), { 0, 0, height },
|
|
{ { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 3, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 1)), { 0, 0, height },
|
|
{ { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 4)), { 0, 0, height },
|
|
{ { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 7)), { 0, 0, height },
|
|
{ { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 10)),
|
|
{ 0, 0, height }, { { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 2)), { 0, 0, height },
|
|
{ { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 5)), { 0, 0, height },
|
|
{ { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 8)), { 0, 0, height },
|
|
{ { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 11)),
|
|
{ 0, 0, height }, { { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 40, session.SupportColours);
|
|
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightCorkscrewUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 12)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 3, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 18)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height - 3, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 13)),
|
|
{ 0, 0, height }, { { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 16)),
|
|
{ 0, 0, height }, { { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 19)),
|
|
{ 0, 0, height }, { { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 22)),
|
|
{ 0, 0, height }, { { 6, 6, height + 10 }, { 20, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 14)),
|
|
{ 0, 0, height }, { { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 17)),
|
|
{ 0, 0, height }, { { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 20)),
|
|
{ 0, 0, height }, { { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_CORKSCREW + 23)),
|
|
{ 0, 0, height }, { { 6, 0, height + 24 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 40, session.SupportColours);
|
|
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftCorkscrewDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightCorkscrewUp(session, ride, 2 - trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
static void GigaRCTrackRightCorkscrewDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftCorkscrewUp(session, ride, 2 - trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeCorkscrewUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 5)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 10)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 21, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 6)),
|
|
{ 0, 0, height }, { { 0, 29, height }, { 26, 1, 32 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 19, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 11)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 20, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 19, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 16, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 2)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 48, 1, 64 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 7)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 28, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 12)),
|
|
{ 0, 0, height }, { { 2, 2, height + 48 }, { 28, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 17)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomLeftSide, PaintSegment::bottomCorner,
|
|
PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 3)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 28, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 8)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 28, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 13)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 24, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 18)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 4)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 28, 28, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 9)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 28, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 14)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 26, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 19)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 26, 28, 1 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomLeftSide, PaintSegment::bottomCorner,
|
|
PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeCorkscrewUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 25)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 30)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height + 4 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomRightSide, PaintSegment::centre, PaintSegment::rightCorner,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 16, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 26)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 20, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 19, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 31)),
|
|
{ 0, 0, height }, { { 0, 29, height }, { 26, 1, 32 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 19, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 36)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 21, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre,
|
|
PaintSegment::bottomRightSide, PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 22)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 27)),
|
|
{ 0, 0, height }, { { 2, 2, height + 48 }, { 28, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 32)),
|
|
{ 0, 0, height }, { { 2, 2, height + 48 }, { 28, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 37)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 48, 1, 64 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 4:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomLeftSide, PaintSegment::bottomCorner,
|
|
PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 23)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 28)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 24, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 33)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 28, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 38)),
|
|
{ 0, 0, height }, { { 2, 2, height + 50 }, { 28, 28, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 0, height + 65,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 24)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 26, 28, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 29)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 26, 28, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 34)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 28, 28, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_CORKSCREW + 39)),
|
|
{ 0, 0, height }, { { 2, 2, height + 40 }, { 28, 28, 1 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomLeftSide, PaintSegment::bottomCorner,
|
|
PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeCorkscrewDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightLargeCorkscrewUp(session, ride, 5 - trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeCorkscrewDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftLargeCorkscrewUp(session, ride, 5 - trackSequence, (direction - 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftMediumHalfLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 5)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 10)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 6)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 0, 32, 64 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 11)),
|
|
{ 0, 0, height }, { { 0, 32, height }, { 40, 0, 64 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::topCorner),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 2)),
|
|
{ 0, 0, height }, { { 0, 0, height + 2 }, { 32, 32, 0 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 14, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 7)),
|
|
{ 0, 0, height }, { { 29, 0, height }, { 1, 32, 96 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 16, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 12)),
|
|
{ 0, 0, height }, { { 31, 0, height }, { 1, 32, 96 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 18, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 17)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 32, 0 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 14, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::centre,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 144, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 3)),
|
|
{ 0, 0, height }, { { 2, 0, height }, { 1, 32, 160 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 8)),
|
|
{ 0, 0, height }, { { 30, 24, height }, { 0, 8, 160 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 13)),
|
|
{ 0, 0, height }, { { 29, 0, height }, { 1, 32, 160 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 18)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 1, 32, 160 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::centre,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 144, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 4)),
|
|
{ 0, 0, height }, { { 0, 2, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 9)),
|
|
{ 0, 0, height }, { { 0, 2, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 14)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 19)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topRightSide, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::rightCorner),
|
|
direction),
|
|
0xFFFF, 0);
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 16, TUNNEL_0);
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightMediumHalfLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 25)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 30)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 7, height, session.SupportColours);
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 26)),
|
|
{ 0, 0, height }, { { 0, 32, height }, { 40, 0, 64 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 31)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 0, 32, 64 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 36)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topRightSide, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::rightCorner),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 22)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 32, 0 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 14, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 27)),
|
|
{ 0, 0, height }, { { 30, 16, height }, { 0, 32, 96 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 18, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 32)),
|
|
{ 0, 0, height }, { { 29, 0, height }, { 0, 32, 96 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 16, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 37)),
|
|
{ 0, 0, height }, { { 0, 0, height + 2 }, { 32, 32, 0 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 14, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::centre,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 144, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 23)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 1, 32, 160 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 28)),
|
|
{ 0, 0, height }, { { 29, 16, height }, { 0, 16, 160 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 33)),
|
|
{ 0, 0, height }, { { 30, 0, height }, { 0, 32, 160 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 38)),
|
|
{ 0, 0, height }, { { 2, 0, height }, { 1, 32, 160 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 144, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 24)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 29)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 34)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_MEDIUM_HALF_LOOP + 39)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::topCorner),
|
|
direction),
|
|
0xFFFF, 0);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 16, TUNNEL_0);
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftMediumHalfLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightMediumHalfLoopUp(session, ride, 4 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightMediumHalfLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftMediumHalfLoopUp(session, ride, 4 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftZeroGRollUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 4)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 5)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 40, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 8)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 12)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 11, height, session.SupportColours);
|
|
break;
|
|
}
|
|
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 2)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 6)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 40, 20, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 9)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 13)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::topCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 3)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 40, 20, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 7)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 10)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 11)),
|
|
{ 0, 0, height }, { { 0, 6, height + 36 }, { 32, 20, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 14)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height + 36 }, { 32, 20, 0 } });
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::topCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 42, session.SupportColours);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightZeroGRollUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 11, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 24)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 25)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 40, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 28)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 29)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 17)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 26)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 44, 1, 32 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 30)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::rightCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 18)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 19)),
|
|
{ 0, 0, height }, { { 0, 6, height + 36 }, { 32, 20, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 22)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 32 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 23)),
|
|
{ 0, 0, height }, { { 0, 6, height + 36 }, { 32, 20, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 27)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 32, 20, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_ZERO_G_ROLL + 31)),
|
|
{ 0, 0, height }, { { 0, 6, height + 32 }, { 40, 20, 1 } });
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::bottomRightSide, PaintSegment::rightCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height + 42, session.SupportColours);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftZeroGRollDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftZeroGRollUp(session, ride, 2 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightZeroGRollDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightZeroGRollUp(session, ride, 2 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeZeroGRollUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 5)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 9)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 10)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 21, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 88, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 2)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 6)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 64 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 11)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 64 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 3)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 64 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 7)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 48 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 12)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 48 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 17)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 32 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 18)),
|
|
{ 0, 0, height }, { { 0, 6, height + 40 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::topCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::topLeftSide, PaintSegment::topCorner,
|
|
PaintSegment::bottomLeftSide, PaintSegment::centre, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 4)),
|
|
{ 0, 0, height }, { { 0, 26, height }, { 32, 0, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 8)),
|
|
{ 0, 0, height }, { { 0, 26, height }, { 26, 0, 20 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 13)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 32 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 14)),
|
|
{ 0, 0, height }, { { 0, 6, height + 40 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 19)),
|
|
{ 0, 0, height }, { { 0, 18, height }, { 32, 1, 30 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeZeroGRollUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 25)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 26)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 31)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 21, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 88, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 27)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 64 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 32)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 64 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 36)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 37)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 96 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 22)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 32 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 23)),
|
|
{ 0, 0, height }, { { 0, 6, height + 40 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 28)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 48 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 33)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 48 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 38)),
|
|
{ 0, 0, height }, { { 0, 30, height }, { 32, 0, 64 } });
|
|
break;
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 24)),
|
|
{ 0, 0, height }, { { 0, 18, height }, { 32, 1, 30 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 29)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 0, 32 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 30)),
|
|
{ 0, 0, height }, { { 0, 6, height + 40 }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 34)),
|
|
{ 0, 0, height }, { { 0, 26, height }, { 32, 0, 30 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_ZERO_G_ROLL + 39)),
|
|
{ 0, 0, height }, { { 0, 26, height }, { 40, 0, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height + 37,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
switch (direction)
|
|
{
|
|
case 1:
|
|
PaintUtilPushTunnelRight(session, height + 8, TUNNEL_0);
|
|
break;
|
|
case 2:
|
|
PaintUtilPushTunnelLeft(session, height + 8, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeZeroGRollDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftLargeZeroGRollUp(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeZeroGRollDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightLargeZeroGRollUp(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrack90DegToInvertedFlatQuarterLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 0)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 3)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 6)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 9)),
|
|
{ 0, 0, height }, { { 4, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomRightSide), direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 88, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 1)),
|
|
{ 0, 0, height }, { { -8, 6, height }, { 2, 20, 31 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 4)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 63 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 7)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 63 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 10)),
|
|
{ 0, 0, height }, { { -8, 6, height }, { 2, 20, 31 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomRightSide), direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 2)),
|
|
{ 0, 0, height }, { { 0, 6, height + 24 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 5)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 8)),
|
|
{ 0, 0, height }, { { 24, 6, height + 8 }, { 2, 20, 31 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_QUARTER_LOOP + 11)),
|
|
{ 0, 0, height }, { { 0, 6, height + 24 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomRightSide), direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackInvertedFlatTo90DegQuarterLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack90DegToInvertedFlatQuarterLoopUp(session, ride, 2 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftBankToLeftQuarterTurn3Tile25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 0)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 2)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 3)),
|
|
{ 0, 6, height }, { { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 5)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 7)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 1)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 4)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 6)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 8)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height - 6, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_2);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_2);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightBankToRightQuarterTurn3Tile25DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 9)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 11)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 13)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 14)),
|
|
{ 0, 6, height }, { { 0, 27, height }, { 32, 1, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 16)),
|
|
{ 0, 6, height }, { 32, 20, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 10)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 12)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 15)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 17)),
|
|
{ 6, 0, height }, { { 0, 6, height - 6 }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height - 6, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_2);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_2);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftQuarterTurn3Tile25DegDownToLeftBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 12)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 15)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 17)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 10)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height - 6, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 11)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 13)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 14)),
|
|
{ 6, 0, height }, { { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 16)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 9)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_0);
|
|
break;
|
|
case 3:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightQuarterTurn3Tile25DegDownToRightBank(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 8)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 1)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 4)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 6)),
|
|
{ 0, 6, height }, { { 0, 6, height - 6 }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height - 6, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 7)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 0)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 2)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 3)),
|
|
{ 6, 0, height }, { { 27, 0, height }, { 1, 32, 26 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_TURN_BANK_TRANSITION + 5)),
|
|
{ 6, 0, height }, { 20, 32, 3 });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintUtilPushTunnelRight(session, height, TUNNEL_0);
|
|
break;
|
|
case 1:
|
|
PaintUtilPushTunnelLeft(session, height, TUNNEL_0);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeHalfLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 7)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 14)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 21)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 1)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 8)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 9 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 15)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 22)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 2)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 9)),
|
|
{ 0, 0, height }, { { 0, 0, height + 70 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 16)),
|
|
{ 0, 0, height }, { { 0, 16, height + 70 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 23)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 88, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 3)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 14, height + 8,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 10)),
|
|
{ 0, 0, height }, { { 0, 0, height + 200 }, { 32, 16, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 14, height + 8,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 17)),
|
|
{ 0, 0, height }, { { 0, 16, height + 200 }, { 32, 16, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 0, height + 21,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 24)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 22, height,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 224, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 4)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 11)),
|
|
{ 0, 0, height }, { { 0, 16, height + 110 }, { 16, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 18)),
|
|
{ 0, 0, height }, { { 0, 0, height + 100 }, { 16, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 25)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 128, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 5)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 12)),
|
|
{ 0, 0, height }, { { 0, 16, height + 200 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 19)),
|
|
{ 0, 0, height }, { { 0, 0, height + 200 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 26)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 224, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 6)),
|
|
{ 0, 0, height }, { { 0, 16, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 13)),
|
|
{ 0, 0, height }, { { 0, 16, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 20)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 27)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeHalfLoopUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 28)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 42)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 49)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 5, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 29)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 36)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 43)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 9 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 50)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 30)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 37)),
|
|
{ 0, 0, height }, { { 0, 16, height + 70 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 44)),
|
|
{ 0, 0, height }, { { 0, 0, height + 70 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 51)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 88, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 31)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomRightSide, 22, height,
|
|
session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 38)),
|
|
{ 0, 0, height }, { { 0, 16, height + 200 }, { 32, 16, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomLeftSide, 0, height + 21,
|
|
session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 45)),
|
|
{ 0, 0, height }, { { 0, 0, height + 200 }, { 32, 16, 0 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopLeftSide, 14, height + 8,
|
|
session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 52)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopRightSide, 14, height + 8,
|
|
session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 224, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 32)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 39)),
|
|
{ 0, 0, height }, { { 0, 0, height + 100 }, { 16, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 46)),
|
|
{ 0, 0, height }, { { 0, 16, height + 110 }, { 16, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 53)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 128, 0x20);
|
|
break;
|
|
case 5:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 33)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 40)),
|
|
{ 0, 0, height }, { { 0, 0, height + 200 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 47)),
|
|
{ 0, 0, height }, { { 0, 16, height + 200 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 54)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 224, 0x20);
|
|
break;
|
|
case 6:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 34)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 41)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 48)),
|
|
{ 0, 0, height }, { { 0, 16, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_LARGE_HALF_LOOP + 55)),
|
|
{ 0, 0, height }, { { 0, 16, height + 32 }, { 32, 16, 0 } });
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 40, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftLargeHalfLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackRightLargeHalfLoopUp(session, ride, 6 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightLargeHalfLoopDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackLeftLargeHalfLoopUp(session, ride, 6 - trackSequence, direction, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackFlatTo60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 0)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 27, 4 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 2)),
|
|
{ 0, 0, height }, { { 29, 4, height + 2 }, { 1, 24, 43 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 1)),
|
|
{ 0, 0, height }, { { 0, 4, height }, { 32, 2, 43 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 4)),
|
|
{ 0, 0, height }, { { 29, 4, height + 2 }, { 1, 24, 43 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 3)),
|
|
{ 0, 0, height }, { { 0, 4, height }, { 32, 2, 43 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 5)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 27, 4 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height, TUNNEL_0);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 24, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrack60DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 6)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 27, 4 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 7)),
|
|
{ 0, 0, height }, { { 0, 4, height }, { 32, 2, 43 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 8)),
|
|
{ 0, 0, height }, { { 29, 4, height + 2 }, { 1, 24, 43 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 10)),
|
|
{ 0, 0, height }, { { 29, 4, height + 2 }, { 1, 24, 43 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 9)),
|
|
{ 0, 0, height }, { { 0, 4, height }, { 32, 2, 43 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 11)),
|
|
{ 0, 0, height }, { { 0, 2, height }, { 32, 27, 4 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 14, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
else
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 24, TUNNEL_0);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
}
|
|
|
|
static void GigaRCTrackFlatTo60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrack60DegUpToFlat(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrack60DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackFlatTo60DegUp(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatTo60DegUp(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 15)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 12)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 14)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 13)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiag60DegUpToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 19)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 16)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 18)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 18, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 17)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 18, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 18, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 18, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatTo60DegDown(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 17)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 18)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 16)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 14, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 19)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 14, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 14, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 14, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiag60DegDownToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 13)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 14)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 12)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_SMALL_FLAT_TO_STEEP + 15)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 4 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 2, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 64, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthToDiagUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 0)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 4)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 8)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 12)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 1)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 5)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 34, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 9)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 13)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 2)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 6)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 10)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 14)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 3)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 7)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 3, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 11)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 15)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 1, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthToDiagUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 16)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 20)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 24)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 28)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 17)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 21)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 25)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 34, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 29)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 18)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 22)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 26)),
|
|
{ 0, 0, height }, { { 4, 4, height }, { 28, 28, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 30)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 19)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 1, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 23)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 2, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 27)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 3, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 31)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 2, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthToOrthogonalUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 32)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 36)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 40)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 3, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 44)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 33)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 37)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 41)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 45)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 34)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 38)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 34, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 42)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 46)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 35)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 39)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 43)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 10 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 47)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height, session.SupportColours);
|
|
|
|
if (direction == 1 || direction == 2)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_2);
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthToOrthogonalUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 48)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 3, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 52)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 56)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 18, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 60)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 49)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 53)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 57)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 61)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 50)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 54)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 58)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 62)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 51)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 10 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 55)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 59)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE + 63)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 3 } });
|
|
break;
|
|
}
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 4, height, session.SupportColours);
|
|
if (direction == 0 || direction == 1)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction + 1, height + 8, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomRightSide), direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthToDiagDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
uint8_t map[5] = { 4, 3, 1, 2, 0 };
|
|
trackSequence = map[trackSequence];
|
|
GigaRCTrackRightEighthToOrthogonalUp25(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthToDiagDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
uint8_t map[5] = { 4, 3, 1, 2, 0 };
|
|
trackSequence = map[trackSequence];
|
|
GigaRCTrackLeftEighthToOrthogonalUp25(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthToOrthogonalDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackRightEighthToDiagUp25(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthToOrthogonalDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackLeftEighthToDiagUp25(session, ride, trackSequence, (direction + 3) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagUp25ToLeftBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 4)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 0)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 1)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 3)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 2)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 10, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 10, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 10, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagUp25ToRightBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 9)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 5)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 7)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 8)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 10, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 6)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 10, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 10, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedUp25ToUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 14)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 10)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 11)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 13)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 12)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 9, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedUp25ToUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 19)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 15)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 17)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 18)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 16)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 9, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagDown25ToLeftBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagRightBankedUp25ToUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagDown25ToRightBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagLeftBankedUp25ToUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedDown25ToDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagUp25ToRightBankedUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedDown25ToDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagUp25ToLeftBankedUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedFlatToLeftBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 23)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 20)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 22)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 21)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedFlatToRightBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 27)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 24)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 26)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 25)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedUp25ToLeftBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 31)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 28)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 30)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 29)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedUp25ToRightBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 35)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 32)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 34)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 33)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 8, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 8, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedFlatToLeftBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagRightBankedUp25ToRightBankedFlat(
|
|
session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedFlatToRightBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagLeftBankedUp25ToLeftBankedFlat(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedDown25ToLeftBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagRightBankedFlatToRightBankedUp25(
|
|
session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedDown25ToRightBankedFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagLeftBankedFlatToLeftBankedUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagUp25LeftBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 39)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 36)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 38)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 37)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 11, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 11, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 11, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagUp25RightBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 43)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 40)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 42)),
|
|
{ -16, -16, height }, { { -16, -16, height + 48 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 11, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 41)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 11, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 11, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagDown25LeftBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagUp25RightBanked(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagDown25RightBanked(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagUp25LeftBanked(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatToLeftBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 48)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 44)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 45)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 47)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 46)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatToRightBankedUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 53)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 49)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 51)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 52)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 50)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 4, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 48, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedUp25ToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 58)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 54)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 55)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 57)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 56)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 6, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedUp25ToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 63)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 59)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 61)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 62)),
|
|
{ -16, -16, height }, { { -16, -16, height + 27 }, { 32, 32, 0 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 60)),
|
|
{ -16, -16, height }, { { -16, -16, height }, { 32, 32, 3 } });
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 6, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
MetalBSupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 6, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 56, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatToLeftBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagRightBankedUp25ToFlat(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagFlatToRightBankedDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagLeftBankedUp25ToFlat(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagLeftBankedDown25ToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagFlatToRightBankedUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackDiagRightBankedDown25ToFlat(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
GigaRCTrackDiagFlatToLeftBankedUp25(session, ride, 3 - trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthBankToDiagUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 64)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height - 4, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 68)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 72)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 9, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 76)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 65)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 69)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 73)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 77)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 66)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 70)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 40, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 74)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 78)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 67)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 71)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 75)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 79)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthBankToDiagUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 80)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 12, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 84)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 9, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 88)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 6, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 92)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 1, height - 4, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 3)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height - 8, TUNNEL_1);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 81)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 85)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 89)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 93)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 82)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 86)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 90)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 40, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 94)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 83)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 87)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 91)),
|
|
{ 0, 0, height }, { { 0, 0, height + 48 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 4, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 95)),
|
|
{ 0, 0, height }, { { 16, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthBankToOrthogonalUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 96)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 100)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 104)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 108)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 97)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 101)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 105)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 109)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::bottomCorner, PaintSegment::centre,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 98)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 102)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 106)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 16, 10 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 110)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 32, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::leftCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide, PaintSegment::bottomLeftSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 99)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 103)),
|
|
{ 0, 0, height }, { { 0, 31, height }, { 32, 1, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 107)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 32, 20, 10 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 111)),
|
|
{ 0, 0, height }, { { 0, 6, height }, { 32, 20, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 9, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 1 || direction == 2)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction, height + 8, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session, PaintUtilRotateSegments(BlockedSegments::kStraightFlat, direction), 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthBankToOrthogonalUp25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
switch (trackSequence)
|
|
{
|
|
case 0:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 112)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::RightCorner, 9, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 116)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::BottomCorner, 7, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 120)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::LeftCorner, 5, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 124)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::TopCorner, 7, height, session.SupportColours);
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::topRightSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 1:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 113)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 16, 3 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 117)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 121)),
|
|
{ 0, 0, height }, { { 0, 0, height + 32 }, { 32, 32, 1 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 125)),
|
|
{ 0, 0, height }, { { 0, 16, height }, { 16, 16, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::topCorner, PaintSegment::rightCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::topRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 2:
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::bottomLeftSide,
|
|
PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 3:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 114)),
|
|
{ 0, 0, height }, { { 0, 0, height }, { 16, 32, 10 } });
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 118)),
|
|
{ 0, 0, height }, { { 31, 0, height }, { 1, 32, 32 } });
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 122)),
|
|
{ 0, 0, height }, { { 31, 0, height }, { 1, 32, 32 } });
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 126)),
|
|
{ 0, 0, height }, { { 16, 0, height }, { 16, 32, 3 } });
|
|
break;
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(
|
|
PaintSegment::leftCorner, PaintSegment::bottomCorner, PaintSegment::centre, PaintSegment::topLeftSide,
|
|
PaintSegment::bottomLeftSide, PaintSegment::bottomRightSide),
|
|
direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
case 4:
|
|
switch (direction)
|
|
{
|
|
case 0:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 115)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 10 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 8, height, session.SupportColours);
|
|
break;
|
|
case 1:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 119)),
|
|
{ 0, 0, height }, { { 31, 0, height }, { 1, 32, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 3, height, session.SupportColours);
|
|
break;
|
|
case 2:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 123)),
|
|
{ 0, 0, height }, { { 31, 0, height }, { 1, 32, 32 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 0, height, session.SupportColours);
|
|
break;
|
|
case 3:
|
|
PaintAddImageAsParentRotated(
|
|
session, direction, session.TrackColours.WithIndex((SPR_G2_GIGA_TRACK_GENTLE_LARGE_CURVE_BANKED + 127)),
|
|
{ 0, 0, height }, { { 6, 0, height }, { 20, 32, 3 } });
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, MetalSupportPlace::Centre, 9, height, session.SupportColours);
|
|
break;
|
|
}
|
|
if (direction == 0 || direction == 1)
|
|
{
|
|
PaintUtilPushTunnelRotated(session, direction + 1, height + 8, TUNNEL_2);
|
|
}
|
|
PaintUtilSetSegmentSupportHeight(
|
|
session,
|
|
PaintUtilRotateSegments(
|
|
EnumsToFlags(PaintSegment::centre, PaintSegment::topLeftSide, PaintSegment::bottomRightSide), direction),
|
|
0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 72, 0x20);
|
|
break;
|
|
}
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthBankToDiagDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
uint8_t map[5] = { 4, 3, 1, 2, 0 };
|
|
trackSequence = map[trackSequence];
|
|
GigaRCTrackRightEighthBankToOrthogonalUp25(session, ride, trackSequence, (direction + 1) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthBankToDiagDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
uint8_t map[5] = { 4, 3, 1, 2, 0 };
|
|
trackSequence = map[trackSequence];
|
|
GigaRCTrackLeftEighthBankToOrthogonalUp25(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackLeftEighthBankToOrthogonalDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackRightEighthBankToDiagUp25(session, ride, trackSequence, (direction + 2) & 3, height, trackElement);
|
|
}
|
|
|
|
static void GigaRCTrackRightEighthBankToOrthogonalDown25(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
trackSequence = mapLeftEighthTurnToOrthogonal[trackSequence];
|
|
GigaRCTrackLeftEighthBankToDiagUp25(session, ride, trackSequence, (direction + 3) & 3, height, trackElement);
|
|
}
|
|
|
|
static constexpr CoordsXYZ diagBrakeBoundsOffsets[4] = {
|
|
{ 0, 0, 24 },
|
|
{ 0, 0, 24 },
|
|
{ 0, 0, 24 },
|
|
{ 0, 0, 24 },
|
|
};
|
|
|
|
static void GigaRCTrackDiagBrakes(
|
|
PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height,
|
|
const TrackElement& trackElement)
|
|
{
|
|
TrackPaintUtilDiagTilesPaint(
|
|
session, 3, height, direction, trackSequence, GigaDiagBrakeImages[trackElement.IsBrakeClosed()][0],
|
|
defaultDiagTileOffsets, defaultDiagBoundLengths, nullptr);
|
|
|
|
TrackPaintUtilDiagTilesPaint(
|
|
session, 3, height, direction, trackSequence, GigaDiagBrakeImages[trackElement.IsBrakeClosed()][1],
|
|
defaultDiagTileOffsets, defaultDiagBoundLengths, diagBrakeBoundsOffsets);
|
|
|
|
if (trackSequence == 3)
|
|
{
|
|
MetalASupportsPaintSetup(
|
|
session, MetalSupportType::Tubes, kDiagSupportPlacement[direction], 0, height, session.SupportColours);
|
|
}
|
|
|
|
PaintUtilSetSegmentSupportHeight(session, kSegmentsAll, 0xFFFF, 0);
|
|
PaintUtilSetGeneralSupportHeight(session, height + 32, 0x20);
|
|
}
|
|
|
|
TRACK_PAINT_FUNCTION GetTrackPaintFunctionGigaRC(int32_t trackType)
|
|
{
|
|
switch (trackType)
|
|
{
|
|
case TrackElemType::Flat:
|
|
return GigaRCTrackFlat;
|
|
case TrackElemType::EndStation:
|
|
case TrackElemType::BeginStation:
|
|
case TrackElemType::MiddleStation:
|
|
return GigaRCTrackStation;
|
|
case TrackElemType::Up25:
|
|
return GigaRCTrack25DegUp;
|
|
case TrackElemType::Up60:
|
|
return GigaRCTrack60DegUp;
|
|
case TrackElemType::FlatToUp25:
|
|
return GigaRCTrackFlatTo25DegUp;
|
|
case TrackElemType::Up25ToUp60:
|
|
return GigaRCTrack25DegUpTo60DegUp;
|
|
case TrackElemType::Up60ToUp25:
|
|
return GigaRCTrack60DegUpTo25DegUp;
|
|
case TrackElemType::Up25ToFlat:
|
|
return GigaRCTrack25DegUpToFlat;
|
|
case TrackElemType::Down25:
|
|
return GigaRCTrack25DegDown;
|
|
case TrackElemType::Down60:
|
|
return GigaRCTrack60DegDown;
|
|
case TrackElemType::FlatToDown25:
|
|
return GigaRCTrackFlatTo25DegDown;
|
|
case TrackElemType::Down25ToDown60:
|
|
return GigaRCTrack25DegDownTo60DegDown;
|
|
case TrackElemType::Down60ToDown25:
|
|
return GigaRCTrack60DegDownTo25DegDown;
|
|
case TrackElemType::Down25ToFlat:
|
|
return GigaRCTrack25DegDownToFlat;
|
|
case TrackElemType::LeftQuarterTurn5Tiles:
|
|
return GigaRCTrackLeftQuarterTurn5;
|
|
case TrackElemType::RightQuarterTurn5Tiles:
|
|
return GigaRCTrackRightQuarterTurn5;
|
|
case TrackElemType::FlatToLeftBank:
|
|
return GigaRCTrackFlatToLeftBank;
|
|
case TrackElemType::FlatToRightBank:
|
|
return GigaRCTrackFlatToRightBank;
|
|
case TrackElemType::LeftBankToFlat:
|
|
return GigaRCTrackLeftBankToFlat;
|
|
case TrackElemType::RightBankToFlat:
|
|
return GigaRCTrackRightBankToFlat;
|
|
case TrackElemType::BankedLeftQuarterTurn5Tiles:
|
|
return GigaRCTrackBankedLeftQuarterTurn5;
|
|
case TrackElemType::BankedRightQuarterTurn5Tiles:
|
|
return GigaRCTrackBankedRightQuarterTurn5;
|
|
case TrackElemType::LeftBankToUp25:
|
|
return GigaRCTrackLeftBankTo25DegUp;
|
|
case TrackElemType::RightBankToUp25:
|
|
return GigaRCTrackRightBankTo25DegUp;
|
|
case TrackElemType::Up25ToLeftBank:
|
|
return GigaRCTrack25DegUpToLeftBank;
|
|
case TrackElemType::Up25ToRightBank:
|
|
return GigaRCTrack25DegUpToRightBank;
|
|
case TrackElemType::LeftBankToDown25:
|
|
return GigaRCTrackLeftBankTo25DegDown;
|
|
case TrackElemType::RightBankToDown25:
|
|
return GigaRCTrackRightBankTo25DegDown;
|
|
case TrackElemType::Down25ToLeftBank:
|
|
return GigaRCTrack25DegDownToLeftBank;
|
|
case TrackElemType::Down25ToRightBank:
|
|
return GigaRCTrack25DegDownToRightBank;
|
|
case TrackElemType::LeftBank:
|
|
return GigaRCTrackLeftBank;
|
|
case TrackElemType::RightBank:
|
|
return GigaRCTrackRightBank;
|
|
case TrackElemType::LeftQuarterTurn5TilesUp25:
|
|
return GigaRCTrackLeftQuarterTurn525DegUp;
|
|
case TrackElemType::RightQuarterTurn5TilesUp25:
|
|
return GigaRCTrackRightQuarterTurn525DegUp;
|
|
case TrackElemType::LeftQuarterTurn5TilesDown25:
|
|
return GigaRCTrackLeftQuarterTurn525DegDown;
|
|
case TrackElemType::RightQuarterTurn5TilesDown25:
|
|
return GigaRCTrackRightQuarterTurn525DegDown;
|
|
case TrackElemType::SBendLeft:
|
|
return GigaRCTrackSBendLeft;
|
|
case TrackElemType::SBendRight:
|
|
return GigaRCTrackSBendRight;
|
|
case TrackElemType::LeftQuarterTurn3Tiles:
|
|
return GigaRCTrackLeftQuarterTurn3;
|
|
case TrackElemType::RightQuarterTurn3Tiles:
|
|
return GigaRCTrackRightQuarterTurn3;
|
|
case TrackElemType::LeftBankedQuarterTurn3Tiles:
|
|
return GigaRCTrackLeftQuarterTurn3Bank;
|
|
case TrackElemType::RightBankedQuarterTurn3Tiles:
|
|
return GigaRCTrackRightQuarterTurn3Bank;
|
|
case TrackElemType::LeftQuarterTurn3TilesUp25:
|
|
return GigaRCTrackLeftQuarterTurn325DegUp;
|
|
case TrackElemType::RightQuarterTurn3TilesUp25:
|
|
return GigaRCTrackRightQuarterTurn325DegUp;
|
|
case TrackElemType::LeftQuarterTurn3TilesDown25:
|
|
return GigaRCTrackLeftQuarterTurn325DegDown;
|
|
case TrackElemType::RightQuarterTurn3TilesDown25:
|
|
return GigaRCTrackRightQuarterTurn325DegDown;
|
|
case TrackElemType::LeftHalfBankedHelixUpSmall:
|
|
return GigaRCTrackLeftHalfBankedHelixUpSmall;
|
|
case TrackElemType::RightHalfBankedHelixUpSmall:
|
|
return GigaRCTrackRightHalfBankedHelixUpSmall;
|
|
case TrackElemType::LeftHalfBankedHelixDownSmall:
|
|
return GigaRCTrackLeftHalfBankedHelixDownSmall;
|
|
case TrackElemType::RightHalfBankedHelixDownSmall:
|
|
return GigaRCTrackRightHalfBankedHelixDownSmall;
|
|
case TrackElemType::LeftHalfBankedHelixUpLarge:
|
|
return GigaRCTrackLeftHalfBankedHelixUpLarge;
|
|
case TrackElemType::RightHalfBankedHelixUpLarge:
|
|
return GigaRCTrackRightHalfBankedHelixUpLarge;
|
|
case TrackElemType::LeftHalfBankedHelixDownLarge:
|
|
return GigaRCTrackLeftHalfBankedHelixDownLarge;
|
|
case TrackElemType::RightHalfBankedHelixDownLarge:
|
|
return GigaRCTrackRightHalfBankedHelixDownLarge;
|
|
case TrackElemType::LeftQuarterTurn1TileUp60:
|
|
return GigaRCTrackLeftQuarterTurn160DegUp;
|
|
case TrackElemType::RightQuarterTurn1TileUp60:
|
|
return GigaRCTrackRightQuarterTurn160DegUp;
|
|
case TrackElemType::LeftQuarterTurn1TileDown60:
|
|
return GigaRCTrackLeftQuarterTurn160DegDown;
|
|
case TrackElemType::RightQuarterTurn1TileDown60:
|
|
return GigaRCTrackRightQuarterTurn160DegDown;
|
|
case TrackElemType::Brakes:
|
|
return GigaRCTrackBrakes;
|
|
case TrackElemType::Up25LeftBanked:
|
|
return GigaRCTrack25DegUpLeftBanked;
|
|
case TrackElemType::Up25RightBanked:
|
|
return GigaRCTrack25DegUpRightBanked;
|
|
case TrackElemType::OnRidePhoto:
|
|
return GigaRCTrackOnRidePhoto;
|
|
case TrackElemType::Down25LeftBanked:
|
|
return GigaRCTrack25DegDownLeftBanked;
|
|
case TrackElemType::Down25RightBanked:
|
|
return GigaRCTrack25DegDownRightBanked;
|
|
case TrackElemType::FlatToUp60LongBase:
|
|
return GigaRCTrackFlatTo60DegUpLongBase;
|
|
case TrackElemType::Up60ToFlatLongBase:
|
|
return GigaRCTrack60DegUpToFlatLongBase;
|
|
case TrackElemType::Down60ToFlatLongBase:
|
|
return GigaRCTrack60DegDownToFlatLongBase;
|
|
case TrackElemType::FlatToDown60LongBase:
|
|
return GigaRCTrackFlatTo60DegDownLongBase;
|
|
case TrackElemType::CableLiftHill:
|
|
return GigaRCTrackCableLiftHill;
|
|
case TrackElemType::LeftEighthToDiag:
|
|
return GigaRCTrackLeftEighthToDiag;
|
|
case TrackElemType::RightEighthToDiag:
|
|
return GigaRCTrackRightEighthToDiag;
|
|
case TrackElemType::LeftEighthToOrthogonal:
|
|
return GigaRCTrackLeftEighthToOrthogonal;
|
|
case TrackElemType::RightEighthToOrthogonal:
|
|
return GigaRCTrackRightEighthToOrthogonal;
|
|
case TrackElemType::LeftEighthBankToDiag:
|
|
return GigaRCTrackLeftEighthBankToDiag;
|
|
case TrackElemType::RightEighthBankToDiag:
|
|
return GigaRCTrackRightEighthBankToDiag;
|
|
case TrackElemType::LeftEighthBankToOrthogonal:
|
|
return GigaRCTrackLeftEighthBankToOrthogonal;
|
|
case TrackElemType::RightEighthBankToOrthogonal:
|
|
return GigaRCTrackRightEighthBankToOrthogonal;
|
|
case TrackElemType::DiagFlat:
|
|
return GigaRCTrackDiagFlat;
|
|
case TrackElemType::DiagUp25:
|
|
return GigaRCTrackDiag25DegUp;
|
|
case TrackElemType::DiagUp60:
|
|
return GigaRCTrackDiag60DegUp;
|
|
case TrackElemType::DiagFlatToUp25:
|
|
return GigaRCTrackDiagFlatTo25DegUp;
|
|
case TrackElemType::DiagUp25ToUp60:
|
|
return GigaRCTrackDiag25DegUpTo60DegUp;
|
|
case TrackElemType::DiagUp60ToUp25:
|
|
return GigaRCTrackDiag60DegUpTo25DegUp;
|
|
case TrackElemType::DiagUp25ToFlat:
|
|
return GigaRCTrackDiag25DegUpToFlat;
|
|
case TrackElemType::DiagDown25:
|
|
return GigaRCTrackDiag25DegDown;
|
|
case TrackElemType::DiagDown60:
|
|
return GigaRCTrackDiag60DegDown;
|
|
case TrackElemType::DiagFlatToDown25:
|
|
return GigaRCTrackDiagFlatTo25DegDown;
|
|
case TrackElemType::DiagDown25ToDown60:
|
|
return GigaRCTrackDiag25DegDownTo60DegDown;
|
|
case TrackElemType::DiagDown60ToDown25:
|
|
return GigaRCTrackDiag60DegDownTo25DegDown;
|
|
case TrackElemType::DiagDown25ToFlat:
|
|
return GigaRCTrackDiag25DegDownToFlat;
|
|
case TrackElemType::DiagFlatToLeftBank:
|
|
return GigaRCTrackDiagFlatToLeftBank;
|
|
case TrackElemType::DiagFlatToRightBank:
|
|
return GigaRCTrackDiagFlatToRightBank;
|
|
case TrackElemType::DiagLeftBankToFlat:
|
|
return GigaRCTrackDiagLeftBankToFlat;
|
|
case TrackElemType::DiagRightBankToFlat:
|
|
return GigaRCTrackDiagRightBankToFlat;
|
|
case TrackElemType::DiagLeftBankToUp25:
|
|
return GigaRCTrackDiagLeftBankTo25DegUp;
|
|
case TrackElemType::DiagRightBankToUp25:
|
|
return GigaRCTrackDiagRightBankTo25DegUp;
|
|
case TrackElemType::DiagUp25ToLeftBank:
|
|
return GigaRCTrackDiag25DegUpToLeftBank;
|
|
case TrackElemType::DiagUp25ToRightBank:
|
|
return GigaRCTrackDiag25DegUpToRightBank;
|
|
case TrackElemType::DiagLeftBankToDown25:
|
|
return GigaRCTrackDiagLeftBankTo25DegDown;
|
|
case TrackElemType::DiagRightBankToDown25:
|
|
return GigaRCTrackDiagRightBankTo25DegDown;
|
|
case TrackElemType::DiagDown25ToLeftBank:
|
|
return GigaRCTrackDiag25DegDownToLeftBank;
|
|
case TrackElemType::DiagDown25ToRightBank:
|
|
return GigaRCTrackDiag25DegDownToRightBank;
|
|
case TrackElemType::DiagLeftBank:
|
|
return GigaRCTrackDiagLeftBank;
|
|
case TrackElemType::DiagRightBank:
|
|
return GigaRCTrackDiagRightBank;
|
|
case TrackElemType::BlockBrakes:
|
|
return GigaRCTrackBlockBrakes;
|
|
case TrackElemType::LeftBankedQuarterTurn3TileUp25:
|
|
return GigaRCTrackLeftBankedQuarterTurn325DegUp;
|
|
case TrackElemType::RightBankedQuarterTurn3TileUp25:
|
|
return GigaRCTrackRightBankedQuarterTurn325DegUp;
|
|
case TrackElemType::LeftBankedQuarterTurn3TileDown25:
|
|
return GigaRCTrackLeftBankedQuarterTurn325DegDown;
|
|
case TrackElemType::RightBankedQuarterTurn3TileDown25:
|
|
return GigaRCTrackRightBankedQuarterTurn325DegDown;
|
|
case TrackElemType::LeftBankedQuarterTurn5TileUp25:
|
|
return GigaRCTrackLeftBankedQuarterTurn525DegUp;
|
|
case TrackElemType::RightBankedQuarterTurn5TileUp25:
|
|
return GigaRCTrackRightBankedQuarterTurn525DegUp;
|
|
case TrackElemType::LeftBankedQuarterTurn5TileDown25:
|
|
return GigaRCTrackLeftBankedQuarterTurn525DegDown;
|
|
case TrackElemType::RightBankedQuarterTurn5TileDown25:
|
|
return GigaRCTrackRightBankedQuarterTurn525DegDown;
|
|
case TrackElemType::Up25ToLeftBankedUp25:
|
|
return GigaRCTrack25DegUpToLeftBanked25DegUp;
|
|
case TrackElemType::Up25ToRightBankedUp25:
|
|
return GigaRCTrack25DegUpToRightBanked25DegUp;
|
|
case TrackElemType::LeftBankedUp25ToUp25:
|
|
return GigaRCTrackLeftBanked25DegUpTo25DegUp;
|
|
case TrackElemType::RightBankedUp25ToUp25:
|
|
return GigaRCTrackRightBanked25DegUpTo25DegUp;
|
|
case TrackElemType::Down25ToLeftBankedDown25:
|
|
return GigaRCTrack25DegDownToLeftBanked25DegDown;
|
|
case TrackElemType::Down25ToRightBankedDown25:
|
|
return GigaRCTrack25DegDownToRightBanked25DegDown;
|
|
case TrackElemType::LeftBankedDown25ToDown25:
|
|
return GigaRCTrackLeftBanked25DegDownTo25DegDown;
|
|
case TrackElemType::RightBankedDown25ToDown25:
|
|
return GigaRCTrackRightBanked25DegDownTo25DegDown;
|
|
case TrackElemType::LeftBankedFlatToLeftBankedUp25:
|
|
return GigaRCTrackLeftBankedFlatToLeftBanked25DegUp;
|
|
case TrackElemType::RightBankedFlatToRightBankedUp25:
|
|
return GigaRCTrackRightBankedFlatToRightBanked25DegUp;
|
|
case TrackElemType::LeftBankedUp25ToLeftBankedFlat:
|
|
return GigaRCTrackLeftBanked25DegUpToLeftBankedFlat;
|
|
case TrackElemType::RightBankedUp25ToRightBankedFlat:
|
|
return GigaRCTrackRightBanked25DegUpToRightBankedFlat;
|
|
case TrackElemType::LeftBankedFlatToLeftBankedDown25:
|
|
return GigaRCTrackLeftBankedFlatToLeftBanked25DegDown;
|
|
case TrackElemType::RightBankedFlatToRightBankedDown25:
|
|
return GigaRCTrackRightBankedFlatToRightBanked25DegDown;
|
|
case TrackElemType::LeftBankedDown25ToLeftBankedFlat:
|
|
return GigaRCTrackLeftBanked25DegDownToLeftBankedFlat;
|
|
case TrackElemType::RightBankedDown25ToRightBankedFlat:
|
|
return GigaRCTrackRightBanked25DegDownToRightBankedFlat;
|
|
case TrackElemType::FlatToLeftBankedUp25:
|
|
return GigaRCTrackFlatToLeftBanked25DegUp;
|
|
case TrackElemType::FlatToRightBankedUp25:
|
|
return GigaRCTrackFlatToRightBanked25DegUp;
|
|
case TrackElemType::LeftBankedUp25ToFlat:
|
|
return GigaRCTrackLeftBanked25DegUpToFlat;
|
|
case TrackElemType::RightBankedUp25ToFlat:
|
|
return GigaRCTrackRightBanked25DegUpToFlat;
|
|
case TrackElemType::FlatToLeftBankedDown25:
|
|
return GigaRCTrackFlatToLeftBanked25DegDown;
|
|
case TrackElemType::FlatToRightBankedDown25:
|
|
return GigaRCTrackFlatToRightBanked25DegDown;
|
|
case TrackElemType::LeftBankedDown25ToFlat:
|
|
return GigaRCTrackLeftBanked25DegDownToFlat;
|
|
case TrackElemType::RightBankedDown25ToFlat:
|
|
return GigaRCTrackRightBanked25DegDownToFlat;
|
|
case TrackElemType::Booster:
|
|
return GigaRCTrackBooster;
|
|
case TrackElemType::PoweredLift:
|
|
return GigaRCTrackPoweredLift;
|
|
|
|
case TrackElemType::Up90:
|
|
return GigaRCTrack90DegUp;
|
|
case TrackElemType::Down90:
|
|
return GigaRCTrack90DegDown;
|
|
case TrackElemType::Up60ToUp90:
|
|
return GigaRCTrack60DegUpTo90DegUp;
|
|
case TrackElemType::Down90ToDown60:
|
|
return GigaRCTrack90DegDownTo60DegDown;
|
|
case TrackElemType::Up90ToUp60:
|
|
return GigaRCTrack90DegUpTo60DegUp;
|
|
case TrackElemType::Down60ToDown90:
|
|
return GigaRCTrack60DegDownTo90DegDown;
|
|
case TrackElemType::LeftQuarterTurn1TileUp90:
|
|
return GigaRCTrackLeftQuarterTurn190DegUp;
|
|
case TrackElemType::RightQuarterTurn1TileUp90:
|
|
return GigaRCTrackRightQuarterTurn190DegUp;
|
|
case TrackElemType::LeftQuarterTurn1TileDown90:
|
|
return GigaRCTrackLeftQuarterTurn190DegDown;
|
|
case TrackElemType::RightQuarterTurn1TileDown90:
|
|
return GigaRCTrackRightQuarterTurn190DegDown;
|
|
case TrackElemType::LeftBarrelRollUpToDown:
|
|
return GigaRCTrackLeftBarrelRollUpToDown;
|
|
case TrackElemType::RightBarrelRollUpToDown:
|
|
return GigaRCTrackRightBarrelRollUpToDown;
|
|
case TrackElemType::LeftBarrelRollDownToUp:
|
|
return GigaRCTrackLeftBarrelRollDownToUp;
|
|
case TrackElemType::RightBarrelRollDownToUp:
|
|
return GigaRCTrackRightBarrelRollDownToUp;
|
|
case TrackElemType::HalfLoopUp:
|
|
return GigaRCTrackHalfLoopUp;
|
|
case TrackElemType::HalfLoopDown:
|
|
return GigaRCTrackHalfLoopDown;
|
|
case TrackElemType::LeftVerticalLoop:
|
|
return GigaRCTrackLeftVerticalLoop;
|
|
case TrackElemType::RightVerticalLoop:
|
|
return GigaRCTrackRightVerticalLoop;
|
|
case TrackElemType::LeftCorkscrewUp:
|
|
return GigaRCTrackLeftCorkscrewUp;
|
|
case TrackElemType::RightCorkscrewUp:
|
|
return GigaRCTrackRightCorkscrewUp;
|
|
case TrackElemType::LeftCorkscrewDown:
|
|
return GigaRCTrackLeftCorkscrewDown;
|
|
case TrackElemType::RightCorkscrewDown:
|
|
return GigaRCTrackRightCorkscrewDown;
|
|
|
|
case TrackElemType::LeftLargeCorkscrewUp:
|
|
return GigaRCTrackLeftLargeCorkscrewUp;
|
|
case TrackElemType::RightLargeCorkscrewUp:
|
|
return GigaRCTrackRightLargeCorkscrewUp;
|
|
case TrackElemType::LeftLargeCorkscrewDown:
|
|
return GigaRCTrackLeftLargeCorkscrewDown;
|
|
case TrackElemType::RightLargeCorkscrewDown:
|
|
return GigaRCTrackRightLargeCorkscrewDown;
|
|
case TrackElemType::LeftZeroGRollUp:
|
|
return GigaRCTrackLeftZeroGRollUp;
|
|
case TrackElemType::RightZeroGRollUp:
|
|
return GigaRCTrackRightZeroGRollUp;
|
|
case TrackElemType::LeftZeroGRollDown:
|
|
return GigaRCTrackLeftZeroGRollDown;
|
|
case TrackElemType::RightZeroGRollDown:
|
|
return GigaRCTrackRightZeroGRollDown;
|
|
case TrackElemType::LeftLargeZeroGRollUp:
|
|
return GigaRCTrackLeftLargeZeroGRollUp;
|
|
case TrackElemType::RightLargeZeroGRollUp:
|
|
return GigaRCTrackRightLargeZeroGRollUp;
|
|
case TrackElemType::LeftLargeZeroGRollDown:
|
|
return GigaRCTrackLeftLargeZeroGRollDown;
|
|
case TrackElemType::RightLargeZeroGRollDown:
|
|
return GigaRCTrackRightLargeZeroGRollDown;
|
|
case TrackElemType::Up90ToInvertedFlatQuarterLoop:
|
|
return GigaRCTrack90DegToInvertedFlatQuarterLoopUp;
|
|
case TrackElemType::InvertedFlatToDown90QuarterLoop:
|
|
return GigaRCTrackInvertedFlatTo90DegQuarterLoopDown;
|
|
case TrackElemType::LeftBankToLeftQuarterTurn3TilesUp25:
|
|
return GigaRCTrackLeftBankToLeftQuarterTurn3Tile25DegUp;
|
|
case TrackElemType::RightBankToRightQuarterTurn3TilesUp25:
|
|
return GigaRCTrackRightBankToRightQuarterTurn3Tile25DegUp;
|
|
case TrackElemType::LeftQuarterTurn3TilesDown25ToLeftBank:
|
|
return GigaRCTrackLeftQuarterTurn3Tile25DegDownToLeftBank;
|
|
case TrackElemType::RightQuarterTurn3TilesDown25ToRightBank:
|
|
return GigaRCTrackRightQuarterTurn3Tile25DegDownToRightBank;
|
|
case TrackElemType::LeftMediumHalfLoopUp:
|
|
return GigaRCTrackLeftMediumHalfLoopUp;
|
|
case TrackElemType::RightMediumHalfLoopUp:
|
|
return GigaRCTrackRightMediumHalfLoopUp;
|
|
case TrackElemType::LeftMediumHalfLoopDown:
|
|
return GigaRCTrackLeftMediumHalfLoopDown;
|
|
case TrackElemType::RightMediumHalfLoopDown:
|
|
return GigaRCTrackRightMediumHalfLoopDown;
|
|
case TrackElemType::LeftLargeHalfLoopUp:
|
|
return GigaRCTrackLeftLargeHalfLoopUp;
|
|
case TrackElemType::RightLargeHalfLoopUp:
|
|
return GigaRCTrackRightLargeHalfLoopUp;
|
|
case TrackElemType::RightLargeHalfLoopDown:
|
|
return GigaRCTrackRightLargeHalfLoopDown;
|
|
case TrackElemType::LeftLargeHalfLoopDown:
|
|
return GigaRCTrackLeftLargeHalfLoopDown;
|
|
case TrackElemType::FlatToUp60:
|
|
return GigaRCTrackFlatTo60DegUp;
|
|
case TrackElemType::Up60ToFlat:
|
|
return GigaRCTrack60DegUpToFlat;
|
|
case TrackElemType::FlatToDown60:
|
|
return GigaRCTrackFlatTo60DegDown;
|
|
case TrackElemType::Down60ToFlat:
|
|
return GigaRCTrack60DegDownToFlat;
|
|
case TrackElemType::DiagFlatToUp60:
|
|
return GigaRCTrackDiagFlatTo60DegUp;
|
|
case TrackElemType::DiagUp60ToFlat:
|
|
return GigaRCTrackDiag60DegUpToFlat;
|
|
case TrackElemType::DiagFlatToDown60:
|
|
return GigaRCTrackDiagFlatTo60DegDown;
|
|
case TrackElemType::DiagDown60ToFlat:
|
|
return GigaRCTrackDiag60DegDownToFlat;
|
|
case TrackElemType::LeftEighthToDiagUp25:
|
|
return GigaRCTrackLeftEighthToDiagUp25;
|
|
case TrackElemType::RightEighthToDiagUp25:
|
|
return GigaRCTrackRightEighthToDiagUp25;
|
|
case TrackElemType::LeftEighthToDiagDown25:
|
|
return GigaRCTrackLeftEighthToDiagDown25;
|
|
case TrackElemType::RightEighthToDiagDown25:
|
|
return GigaRCTrackRightEighthToDiagDown25;
|
|
case TrackElemType::LeftEighthToOrthogonalUp25:
|
|
return GigaRCTrackLeftEighthToOrthogonalUp25;
|
|
case TrackElemType::RightEighthToOrthogonalUp25:
|
|
return GigaRCTrackRightEighthToOrthogonalUp25;
|
|
case TrackElemType::LeftEighthToOrthogonalDown25:
|
|
return GigaRCTrackLeftEighthToOrthogonalDown25;
|
|
case TrackElemType::RightEighthToOrthogonalDown25:
|
|
return GigaRCTrackRightEighthToOrthogonalDown25;
|
|
case TrackElemType::DiagUp25ToLeftBankedUp25:
|
|
return GigaRCTrackDiagUp25ToLeftBankedUp25;
|
|
case TrackElemType::DiagUp25ToRightBankedUp25:
|
|
return GigaRCTrackDiagUp25ToRightBankedUp25;
|
|
case TrackElemType::DiagLeftBankedUp25ToUp25:
|
|
return GigaRCTrackDiagLeftBankedUp25ToUp25;
|
|
case TrackElemType::DiagRightBankedUp25ToUp25:
|
|
return GigaRCTrackDiagRightBankedUp25ToUp25;
|
|
case TrackElemType::DiagDown25ToLeftBankedDown25:
|
|
return GigaRCTrackDiagDown25ToLeftBankedDown25;
|
|
case TrackElemType::DiagDown25ToRightBankedDown25:
|
|
return GigaRCTrackDiagDown25ToRightBankedDown25;
|
|
case TrackElemType::DiagLeftBankedDown25ToDown25:
|
|
return GigaRCTrackDiagLeftBankedDown25ToDown25;
|
|
case TrackElemType::DiagRightBankedDown25ToDown25:
|
|
return GigaRCTrackDiagRightBankedDown25ToDown25;
|
|
case TrackElemType::DiagLeftBankedFlatToLeftBankedUp25:
|
|
return GigaRCTrackDiagLeftBankedFlatToLeftBankedUp25;
|
|
case TrackElemType::DiagRightBankedFlatToRightBankedUp25:
|
|
return GigaRCTrackDiagRightBankedFlatToRightBankedUp25;
|
|
case TrackElemType::DiagLeftBankedUp25ToLeftBankedFlat:
|
|
return GigaRCTrackDiagLeftBankedUp25ToLeftBankedFlat;
|
|
case TrackElemType::DiagRightBankedUp25ToRightBankedFlat:
|
|
return GigaRCTrackDiagRightBankedUp25ToRightBankedFlat;
|
|
case TrackElemType::DiagLeftBankedFlatToLeftBankedDown25:
|
|
return GigaRCTrackDiagLeftBankedFlatToLeftBankedDown25;
|
|
case TrackElemType::DiagRightBankedFlatToRightBankedDown25:
|
|
return GigaRCTrackDiagRightBankedFlatToRightBankedDown25;
|
|
case TrackElemType::DiagLeftBankedDown25ToLeftBankedFlat:
|
|
return GigaRCTrackDiagLeftBankedDown25ToLeftBankedFlat;
|
|
case TrackElemType::DiagRightBankedDown25ToRightBankedFlat:
|
|
return GigaRCTrackDiagRightBankedDown25ToRightBankedFlat;
|
|
case TrackElemType::DiagUp25LeftBanked:
|
|
return GigaRCTrackDiagUp25LeftBanked;
|
|
case TrackElemType::DiagUp25RightBanked:
|
|
return GigaRCTrackDiagUp25RightBanked;
|
|
case TrackElemType::DiagDown25LeftBanked:
|
|
return GigaRCTrackDiagDown25LeftBanked;
|
|
case TrackElemType::DiagDown25RightBanked:
|
|
return GigaRCTrackDiagDown25RightBanked;
|
|
case TrackElemType::DiagFlatToLeftBankedUp25:
|
|
return GigaRCTrackDiagFlatToLeftBankedUp25;
|
|
case TrackElemType::DiagFlatToRightBankedUp25:
|
|
return GigaRCTrackDiagFlatToRightBankedUp25;
|
|
case TrackElemType::DiagLeftBankedUp25ToFlat:
|
|
return GigaRCTrackDiagLeftBankedUp25ToFlat;
|
|
case TrackElemType::DiagRightBankedUp25ToFlat:
|
|
return GigaRCTrackDiagRightBankedUp25ToFlat;
|
|
case TrackElemType::DiagFlatToLeftBankedDown25:
|
|
return GigaRCTrackDiagFlatToLeftBankedDown25;
|
|
case TrackElemType::DiagFlatToRightBankedDown25:
|
|
return GigaRCTrackDiagFlatToRightBankedDown25;
|
|
case TrackElemType::DiagLeftBankedDown25ToFlat:
|
|
return GigaRCTrackDiagLeftBankedDown25ToFlat;
|
|
case TrackElemType::DiagRightBankedDown25ToFlat:
|
|
return GigaRCTrackDiagRightBankedDown25ToFlat;
|
|
case TrackElemType::LeftEighthBankToDiagUp25:
|
|
return GigaRCTrackLeftEighthBankToDiagUp25;
|
|
case TrackElemType::RightEighthBankToDiagUp25:
|
|
return GigaRCTrackRightEighthBankToDiagUp25;
|
|
case TrackElemType::LeftEighthBankToDiagDown25:
|
|
return GigaRCTrackLeftEighthBankToDiagDown25;
|
|
case TrackElemType::RightEighthBankToDiagDown25:
|
|
return GigaRCTrackRightEighthBankToDiagDown25;
|
|
case TrackElemType::LeftEighthBankToOrthogonalUp25:
|
|
return GigaRCTrackLeftEighthBankToOrthogonalUp25;
|
|
case TrackElemType::RightEighthBankToOrthogonalUp25:
|
|
return GigaRCTrackRightEighthBankToOrthogonalUp25;
|
|
case TrackElemType::LeftEighthBankToOrthogonalDown25:
|
|
return GigaRCTrackLeftEighthBankToOrthogonalDown25;
|
|
case TrackElemType::RightEighthBankToOrthogonalDown25:
|
|
return GigaRCTrackRightEighthBankToOrthogonalDown25;
|
|
case TrackElemType::DiagBlockBrakes:
|
|
case TrackElemType::DiagBrakes:
|
|
return GigaRCTrackDiagBrakes;
|
|
}
|
|
return nullptr;
|
|
}
|