OpenTTD Source  13.2.1
station_cmd.h
Go to the documentation of this file.
1 /*
2  * This file is part of OpenTTD.
3  * 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.
4  * 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.
5  * 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/>.
6  */
7 
10 #ifndef STATION_CMD_H
11 #define STATION_CMD_H
12 
13 #include "command_type.h"
14 #include "station_type.h"
15 
16 enum StationClassID : byte;
17 
18 CommandCost CmdBuildAirport(DoCommandFlag flags, TileIndex tile, byte airport_type, byte layout, StationID station_to_join, bool allow_adjacent);
19 CommandCost CmdBuildDock(DoCommandFlag flags, TileIndex tile, StationID station_to_join, bool adjacent);
20 CommandCost CmdBuildRailStation(DoCommandFlag flags, TileIndex tile_org, RailType rt, Axis axis, byte numtracks, byte plat_len, StationClassID spec_class, byte spec_index, StationID station_to_join, bool adjacent);
21 CommandCost CmdRemoveFromRailStation(DoCommandFlag flags, TileIndex start, TileIndex end, bool keep_rail);
22 CommandCost CmdBuildRoadStop(DoCommandFlag flags, TileIndex tile, uint8 width, uint8 length, RoadStopType stop_type, bool is_drive_through, DiagDirection ddir, RoadType rt, StationID station_to_join, bool adjacent);
23 CommandCost CmdRemoveRoadStop(DoCommandFlag flags, TileIndex tile, uint8 width, uint8 height, RoadStopType stop_type, bool remove_road);
24 CommandCost CmdRenameStation(DoCommandFlag flags, StationID station_id, const std::string &text);
25 CommandCost CmdOpenCloseAirport(DoCommandFlag flags, StationID station_id);
26 
35 
36 #endif /* STATION_CMD_H */
CMD_BUILD_DOCK
@ CMD_BUILD_DOCK
build a dock
Definition: command_type.h:209
CMD_RENAME_STATION
@ CMD_RENAME_STATION
rename a station
Definition: command_type.h:250
CMD_REMOVE_ROAD_STOP
@ CMD_REMOVE_ROAD_STOP
remove a road stop
Definition: command_type.h:200
RoadStopType
RoadStopType
Types of RoadStops.
Definition: station_type.h:44
CmdOpenCloseAirport
CommandCost CmdOpenCloseAirport(DoCommandFlag flags, StationID station_id)
Open/close an airport to incoming aircraft.
Definition: station_cmd.cpp:2422
Axis
Axis
Allow incrementing of DiagDirDiff variables.
Definition: direction_type.h:125
CMD_BUILD_ROAD_STOP
@ CMD_BUILD_ROAD_STOP
build a road stop
Definition: command_type.h:199
TileIndex
The index/ID of a Tile.
Definition: tile_type.h:85
CMD_BUILD_RAIL_STATION
@ CMD_BUILD_RAIL_STATION
build a rail station
Definition: command_type.h:183
CmdBuildAirport
enum StationClassID byte CommandCost CmdBuildAirport(DoCommandFlag flags, TileIndex tile, byte airport_type, byte layout, StationID station_to_join, bool allow_adjacent)
Place an Airport.
Definition: station_cmd.cpp:2211
DoCommandFlag
DoCommandFlag
List of flags for a command.
Definition: command_type.h:355
CmdRemoveRoadStop
CommandCost CmdRemoveRoadStop(DoCommandFlag flags, TileIndex tile, uint8 width, uint8 height, RoadStopType stop_type, bool remove_road)
Remove bus or truck stops.
Definition: station_cmd.cpp:2058
RailType
RailType
Enumeration for all possible railtypes.
Definition: rail_type.h:27
CommandCost
Common return value for all commands.
Definition: command_type.h:24
CMDT_OTHER_MANAGEMENT
@ CMDT_OTHER_MANAGEMENT
Renaming stuff, changing company colours, placing signs, etc.
Definition: command_type.h:400
CMD_AUTO
@ CMD_AUTO
set the DC_AUTO flag on this command
Definition: command_type.h:381
CmdBuildRailStation
CommandCost CmdBuildRailStation(DoCommandFlag flags, TileIndex tile_org, RailType rt, Axis axis, byte numtracks, byte plat_len, StationClassID spec_class, byte spec_index, StationID station_to_join, bool adjacent)
Build rail station.
Definition: station_cmd.cpp:1260
CMDT_ROUTE_MANAGEMENT
@ CMDT_ROUTE_MANAGEMENT
Modifications to route management (orders, groups, etc).
Definition: command_type.h:399
CMD_REMOVE_FROM_RAIL_STATION
@ CMD_REMOVE_FROM_RAIL_STATION
remove a (rectangle of) tiles from a rail station
Definition: command_type.h:192
CmdBuildRoadStop
CommandCost CmdBuildRoadStop(DoCommandFlag flags, TileIndex tile, uint8 width, uint8 length, RoadStopType stop_type, bool is_drive_through, DiagDirection ddir, RoadType rt, StationID station_to_join, bool adjacent)
Build a bus or truck stop.
Definition: station_cmd.cpp:1827
DiagDirection
DiagDirection
Enumeration for diagonal directions.
Definition: direction_type.h:77
CmdRemoveFromRailStation
CommandCost CmdRemoveFromRailStation(DoCommandFlag flags, TileIndex start, TileIndex end, bool keep_rail)
Remove a single tile from a rail station.
Definition: station_cmd.cpp:1657
command_type.h
CMD_BUILD_AIRPORT
@ CMD_BUILD_AIRPORT
build an airport
Definition: command_type.h:207
CMD_NO_WATER
@ CMD_NO_WATER
set the DC_NO_WATER flag on this command
Definition: command_type.h:384
CMD_OPEN_CLOSE_AIRPORT
@ CMD_OPEN_CLOSE_AIRPORT
open/close an airport to incoming aircraft
Definition: command_type.h:339
CmdRenameStation
CommandCost CmdRenameStation(DoCommandFlag flags, StationID station_id, const std::string &text)
Rename a station.
Definition: station_cmd.cpp:3897
StationClassID
StationClassID
Definition: newgrf_station.h:83
RoadType
RoadType
The different roadtypes we support.
Definition: road_type.h:22
CmdBuildDock
CommandCost CmdBuildDock(DoCommandFlag flags, TileIndex tile, StationID station_to_join, bool adjacent)
Build a dock/haven.
Definition: station_cmd.cpp:2476
CMDT_LANDSCAPE_CONSTRUCTION
@ CMDT_LANDSCAPE_CONSTRUCTION
Construction and destruction of objects on the map.
Definition: command_type.h:395
station_type.h