MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / getOneWayArrowImage

Function getOneWayArrowImage

src/OpenLoco/src/Paint/PaintSignal.cpp:131–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

129 }
130
131 static uint32_t getOneWayArrowImage(const bool isRight, const uint8_t trackId, const uint8_t rotation)
132 {
133 const auto& trackCoordinates = World::TrackData::getUnkTrack((trackId << 3) | rotation);
134 if (isRight)
135 {
136 return kOneWayArrowRight[trackCoordinates.rotationBegin];
137 }
138 else
139 {
140 return kOneWayArrowLeft[trackCoordinates.rotationEnd];
141 }
142 }
143
144 static void paintSignalSide(PaintSession& session, const World::SignalElement::Side& side, const bool isRight, const bool isGhost, const uint8_t trackId, const uint8_t rotation, const coord_t height)
145 {

Callers 1

paintSignalSideFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected