MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / GetLayout

Method GetLayout

src/newgrf_commons.h:167–177  ·  view source on GitHub ↗

* Returns the result spritelayout after preprocessing. * @return result ground sprite and spritelayout */

Source from the content-addressed store, hash-verified

165 * @return result ground sprite and spritelayout
166 */
167 DrawTileSpriteSpan GetLayout() const
168 {
169 assert(this->raw_layout != nullptr);
170 if (this->result_seq.empty()) {
171 /* Simple layout without preprocessing. */
172 return {this->raw_layout->ground, this->raw_layout->seq};
173 } else {
174 /* Dynamic layout with preprocessing. */
175 return {this->result_seq[0].image, {++this->result_seq.begin(), this->result_seq.end()}};
176 }
177 }
178};
179
180/**

Callers 9

DrawRoadStopTileFunction · 0.80
DrawStationTileFunction · 0.80
DrawNewHouseTileFunction · 0.80
DrawNewHouseTileInGUIFunction · 0.80
DrawNewAirportTileFunction · 0.80
DrawTile_StationFunction · 0.80
DrawNewObjectTileFunction · 0.80
DrawNewObjectTileInGUIFunction · 0.80
DrawNewIndustryTileFunction · 0.80

Calls 3

emptyMethod · 0.45
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected