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

Function DrawPillarColumn

src/tunnelbridge_cmd.cpp:1078–1085  ·  view source on GitHub ↗

* Draw two bridge pillars (north and south). * @param z_bottom Bottom Z * @param z_top Top Z * @param psid Pillarsprite * @param x Pillar X * @param y Pillar Y * @param w Bounding box size in X direction * @param h Bounding box size in Y direction * @return Reached Z at the bottom */

Source from the content-addressed store, hash-verified

1076 * @return Reached Z at the bottom
1077 */
1078static int DrawPillarColumn(int z_bottom, int z_top, const PalSpriteID &psid, int x, int y, int w, int h)
1079{
1080 int cur_z;
1081 for (cur_z = z_top; cur_z >= z_bottom; cur_z -= TILE_HEIGHT) {
1082 DrawPillar(psid, x, y, cur_z, w, h, nullptr);
1083 }
1084 return cur_z;
1085}
1086
1087/**
1088 * Draws the pillars under high bridges.

Callers 1

DrawBridgePillarsFunction · 0.85

Calls 1

DrawPillarFunction · 0.85

Tested by

no test coverage detected