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

Function updateDisplayCS

src/OpenLoco/src/Intro.cpp:110–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

108 }
109 }
110 static void updateDisplayCS(Gfx::DrawingContext& drawingCtx)
111 {
112 _introTicks++;
113 uint8_t modifier = 0;
114 if (_introTicks >= 0)
115 {
116 modifier = _introTicks;
117 if (_introTicks >= 50)
118 {
119 modifier = 100 - _introTicks;
120 }
121 }
122 modifier = std::min(255, modifier * 8);
123
124 Gfx::loadPalette(ImageIds::chris_sawyer_intro_palette, modifier);
125 if (_introTicks >= 100)
126 {
127 drawingCtx.clearSingle(PaletteIndex::black0);
128
129 _state = State::displayNoticeBegin;
130 }
131 }
132 static void updateState4([[maybe_unused]] Gfx::DrawingContext& drawingCtx) {}
133 static void updateState5([[maybe_unused]] Gfx::DrawingContext& drawingCtx) {}
134 static void updateState6([[maybe_unused]] Gfx::DrawingContext& drawingCtx) {}

Callers

nothing calls this directly

Calls 2

loadPaletteFunction · 0.85
clearSingleMethod · 0.80

Tested by

no test coverage detected