| 948 | } |
| 949 | |
| 950 | static void DrawTile_Water(TileInfo *ti) |
| 951 | { |
| 952 | switch (GetWaterTileType(ti->tile)) { |
| 953 | case WaterTileType::Clear: |
| 954 | DrawWaterClassGround(ti); |
| 955 | /* A plain water tile can be traversed in any direction, so setting blocked pillars here would mean all bridges |
| 956 | * with edges would have no pillars above water. Instead prefer current behaviour of ships passing through. */ |
| 957 | DrawBridgeMiddle(ti, {}); |
| 958 | break; |
| 959 | |
| 960 | case WaterTileType::Coast: { |
| 961 | DrawShoreTile(ti->tileh); |
| 962 | DrawBridgeMiddle(ti, {}); |
| 963 | break; |
| 964 | } |
| 965 | |
| 966 | case WaterTileType::Lock: |
| 967 | DrawWaterLock(ti); |
| 968 | DrawBridgeMiddle(ti, DiagDirToAxis(GetLockDirection(ti->tile)) == AXIS_X |
| 969 | ? BridgePillarFlags{BridgePillarFlag::EdgeNE, BridgePillarFlag::EdgeSW} |
| 970 | : BridgePillarFlags{BridgePillarFlag::EdgeNW, BridgePillarFlag::EdgeSE}); |
| 971 | break; |
| 972 | |
| 973 | case WaterTileType::Depot: |
| 974 | DrawWaterDepot(ti); |
| 975 | break; |
| 976 | } |
| 977 | } |
| 978 | |
| 979 | void DrawShipDepotSprite(int x, int y, Axis axis, DepotPart part) |
| 980 | { |
nothing calls this directly
no test coverage detected