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/>.
8 /** @file waypoint_cmd.h Command definitions related to waypoints. */
10 #ifndef WAYPOINT_CMD_H
11 #define WAYPOINT_CMD_H
13 #include "command_type.h"
14 #include "station_type.h"
16 enum StationClassID
: byte
;
18 CommandCost
CmdBuildRailWaypoint(DoCommandFlag flags
, TileIndex start_tile
, Axis axis
, byte width
, byte height
, StationClassID spec_class
, uint16_t spec_index
, StationID station_to_join
, bool adjacent
);
19 CommandCost
CmdRemoveFromRailWaypoint(DoCommandFlag flags
, TileIndex start
, TileIndex end
, bool keep_rail
);
20 CommandCost
CmdBuildBuoy(DoCommandFlag flags
, TileIndex tile
);
21 CommandCost
CmdRenameWaypoint(DoCommandFlag flags
, StationID waypoint_id
, const std::string
&text
);
23 DEF_CMD_TRAIT(CMD_BUILD_RAIL_WAYPOINT
, CmdBuildRailWaypoint
, 0, CMDT_LANDSCAPE_CONSTRUCTION
)
24 DEF_CMD_TRAIT(CMD_REMOVE_FROM_RAIL_WAYPOINT
, CmdRemoveFromRailWaypoint
, 0, CMDT_LANDSCAPE_CONSTRUCTION
)
25 DEF_CMD_TRAIT(CMD_BUILD_BUOY
, CmdBuildBuoy
, CMD_AUTO
, CMDT_LANDSCAPE_CONSTRUCTION
)
26 DEF_CMD_TRAIT(CMD_RENAME_WAYPOINT
, CmdRenameWaypoint
, 0, CMDT_OTHER_MANAGEMENT
)
28 #endif /* WAYPOINT_CMD_H */