0x00458C7F
| 102 | |
| 103 | // 0x00458C7F |
| 104 | void IndustryObject::drawIndustry(Gfx::DrawingContext& drawingCtx, int16_t x, int16_t y) const |
| 105 | { |
| 106 | auto firstColour = Numerics::bitScanReverse(availableColours); |
| 107 | Colour c = firstColour != -1 ? static_cast<Colour>(firstColour) |
| 108 | : Colour::black; |
| 109 | ImageId baseImage(buildingImageIds, c); |
| 110 | Ui::Point pos{ x, y }; |
| 111 | const auto partHeights = getBuildingPartHeights(); |
| 112 | for (const auto part : getBuildingParts(0)) |
| 113 | { |
| 114 | auto image = baseImage.withIndexOffset(part * 4 + 1); |
| 115 | drawingCtx.drawImage(pos, image); |
| 116 | pos.y -= partHeights[part]; |
| 117 | } |
| 118 | } |
| 119 | |
| 120 | // 0x0045926F |
| 121 | bool IndustryObject::validate() const |
no test coverage detected