|
OpenTTD Source 20260621-master-g720d10536d
|
Handling of NewGRF canals. More...
Go to the source code of this file.
Data Structures | |
| struct | WaterFeature |
| Information about a water feature. More... | |
Functions | |
| SpriteID | GetCanalSprite (CanalFeature feature, TileIndex tile) |
| Lookup the base sprite to use for a canal. | |
| uint | GetCanalSpriteOffset (CanalFeature feature, TileIndex tile, uint cur_offset) |
| Get the new sprite offset for a water tile. | |
Variables | |
| EnumIndexArray< WaterFeature, CanalFeature, CanalFeature::End > | _water_feature |
| Table of canal 'feature' sprite groups. | |
Handling of NewGRF canals.
Definition in file newgrf_canal.h.
| SpriteID GetCanalSprite | ( | CanalFeature | feature, |
| TileIndex | tile ) |
Lookup the base sprite to use for a canal.
| feature | Which canal feature we want. |
| tile | Tile index of canal, if appropriate. |
0 if none. Definition at line 139 of file newgrf_canal.cpp.
Referenced by DrawCanalWater(), DrawTile_Station(), DrawWaterEdges(), and DrawWaterLock().
| uint GetCanalSpriteOffset | ( | CanalFeature | feature, |
| TileIndex | tile, | ||
| uint | cur_offset ) |
Get the new sprite offset for a water tile.
| tile | Tile index of the canal/water tile. |
| feature | For which feature to get the new sprite offset. |
| cur_offset | Current sprite offset. |
Definition at line 171 of file newgrf_canal.cpp.
References _water_feature, CALLBACK_FAILED, CBID_CANALS_SPRITE_OFFSET, GetCanalCallback(), and SpriteOffset.
Referenced by DrawWaterSprite(), and DrawWaterTileStruct().
|
extern |
Table of canal 'feature' sprite groups.
Definition at line 20 of file newgrf_canal.cpp.
Referenced by CanalResolverObject::CanalResolverObject(), DrawCanalWater(), DrawWaterLock(), FinaliseCanals(), GetCanalSpriteOffset(), CanalMapSpriteGroupHandler::MapDefault(), and ResetNewGRFData().