|
OpenTTD Source 20260206-master-g4d4e37dbf1
|
Command definitions related to water tiles. More...
Go to the source code of this file.
Functions | |
| CommandCost | CmdBuildShipDepot (DoCommandFlags flags, TileIndex tile, Axis axis) |
| Build a ship depot. | |
| CommandCost | CmdBuildCanal (DoCommandFlags flags, TileIndex tile, TileIndex start_tile, WaterClass wc, bool diagonal) |
| Build a piece of canal. | |
| CommandCost | CmdBuildLock (DoCommandFlags flags, TileIndex tile) |
| Builds a lock. | |
Command definitions related to water tiles.
Definition in file water_cmd.h.
| CommandCost CmdBuildCanal | ( | DoCommandFlags | flags, |
| TileIndex | tile, | ||
| TileIndex | start_tile, | ||
| WaterClass | wc, | ||
| bool | diagonal ) |
Build a piece of canal.
| flags | type of operation |
| tile | end tile of stretch-dragging |
| start_tile | start tile of stretch-dragging |
| wc | waterclass to build. sea and river can only be built in scenario editor |
| diagonal | Whether to use the Orthogonal (0) or Diagonal (1) iterator. |
Definition at line 493 of file water_cmd.cpp.
References _current_company, CommandCost::AddCost(), BuildCanal, Canal, CheckForDockingTile(), CMD_ERROR, TileIterator::Create(), DirtyCompanyInfrastructureWindows(), Execute, EXPENSES_CONSTRUCTION, CommandCost::Failed(), CommandCost::GetCost(), GetTileOwner(), GetTileSlope(), GetTropicZone(), INVALID_TILE, IsCanal(), IsInclinedSlope(), IsTileOwner(), IsTileType(), IsValidWaterClass(), IsWaterTile(), MakeCanal(), MakeRiver(), MakeSea(), MarkCanalsAndRiversAroundDirty(), MarkTileDirtyByTile(), OWNER_NONE, River, RIVER_OFFSET_DESERT_DISTANCE, Sea, SetTropicZone(), Map::Size(), SLOPE_FLAT, BaseBitSet< Timpl, Tvalue_type, Tstorage, Tmask >::Test(), TileHeight(), TROPICZONE_DESERT, TROPICZONE_NORMAL, and Water.
| CommandCost CmdBuildLock | ( | DoCommandFlags | flags, |
| TileIndex | tile ) |
Builds a lock.
| flags | type of operation |
| tile | tile where to place the lock |
Definition at line 454 of file water_cmd.cpp.
References _settings_game, DoBuildLock(), GetInclinedSlopeDirection(), GetTileSlope(), INVALID_DIAGDIR, IsInsideMM(), Map::MaxX(), Map::MaxY(), ReverseDiagDir(), TileAddByDiagDir(), TileX(), and TileY().
| CommandCost CmdBuildShipDepot | ( | DoCommandFlags | flags, |
| TileIndex | tile, | ||
| Axis | axis ) |
Build a ship depot.
| flags | type of operation |
| tile | tile where ship depot is built |
| axis | depot orientation (Axis) |
Definition at line 113 of file water_cmd.cpp.
References _current_company, CommandCost::AddCost(), Auto, BuildDepotShip, Canal, CheckForDockingTile(), CMD_ERROR, DirtyCompanyInfrastructureWindows(), Execute, EXPENSES_CONSTRUCTION, CommandCost::Failed(), CommandCost::GetCost(), GetWaterClass(), HasTileWaterClass(), HasTileWaterGround(), IsBridgeAbove(), IsTileFlat(), IsTileOwner(), IsValidAxis(), IsWaterTile(), LOCK_DEPOT_TILE_FACTOR, MakeDefaultName(), MakeShipDepot(), MarkTileDirtyByTile(), North, South, BaseBitSet< Timpl, Tvalue_type, Tstorage, Tmask >::Test(), and TileOffsByAxis().