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

Function directionFlipXAxis

src/OpenLoco/src/Paint/Paint.cpp:111–114  ·  view source on GitHub ↗

* Flips the X axis so 1 and 3 are swapped 0 and 2 will stay the same. * { 0, 3, 2, 1 } */

Source from the content-addressed store, hash-verified

109 * { 0, 3, 2, 1 }
110 */
111 inline constexpr uint8_t directionFlipXAxis(const uint8_t direction)
112 {
113 return (direction * 3) % 4;
114 }
115
116 static int32_t remapPositionToQuadrant(const PaintStruct& ps, uint8_t rotation)
117 {

Callers 2

generateParametersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected