OpenTTD
road_internal.h
Go to the documentation of this file.
1 /* $Id: road_internal.h 27676 2016-11-05 11:53:03Z frosch $ */
2 
3 /*
4  * This file is part of OpenTTD.
5  * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
6  * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
7  * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
8  */
9 
12 #ifndef ROAD_INTERNAL_H
13 #define ROAD_INTERNAL_H
14 
15 #include "tile_cmd.h"
16 #include "road_type.h"
17 
18 RoadBits CleanUpRoadBits(const TileIndex tile, RoadBits org_rb);
19 
20 CommandCost CheckAllowRemoveRoad(TileIndex tile, RoadBits remove, Owner owner, RoadType rt, DoCommandFlag flags, bool town_check = true);
21 
22 void DrawRoadCatenary(const TileInfo *ti, RoadBits tram);
23 
24 #endif /* ROAD_INTERNAL_H */
Enums and other types related to roads.
Tile information, used while rendering the tile.
Definition: tile_cmd.h:44
WindowFlags flags
Window flags.
Definition: window_gui.h:305
void DrawRoadCatenary(const TileInfo *ti, RoadBits tram)
Draws the catenary for the given tile.
Definition: road_cmd.cpp:1194
Common return value for all commands.
Definition: command_type.h:25
RoadType
The different roadtypes we support.
Definition: road_type.h:22
DoCommandFlag
List of flags for a command.
Definition: command_type.h:340
RoadBits
Enumeration for the road parts on a tile.
Definition: road_type.h:55
RoadBits CleanUpRoadBits(const TileIndex tile, RoadBits org_rb)
Clean up unnecessary RoadBits of a planed tile.
Definition: road.cpp:46
uint32 TileIndex
The index/ID of a Tile.
Definition: tile_type.h:80
Owner owner
The owner of the content shown in this window. Company colour is acquired from this variable...
Definition: window_gui.h:319
Owner
Enum for all companies/owners.
Definition: company_type.h:20
CommandCost CheckAllowRemoveRoad(TileIndex tile, RoadBits remove, Owner owner, RoadType rt, DoCommandFlag flags, bool town_check=true)
Is it allowed to remove the given road bits from the given tile?
Definition: road_cmd.cpp:116
Generic &#39;commands&#39; that can be performed on all tiles.