src/command.h
author skidd13
Sun, 02 Dec 2007 21:43:16 +0000
changeset 8004 1c54bc6f4bdf
parent 7560 7f9b639f30af
permissions -rw-r--r--
(svn r11563) -Codechange: Align the preprocessor code in stdafx.h with tabs
2186
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 1820
diff changeset
     1
/* $Id$ */
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 1820
diff changeset
     2
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
     3
/** @file command.h */
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
     4
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     5
#ifndef COMMAND_H
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     6
#define COMMAND_H
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     7
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
     8
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
     9
 * List of commands.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    10
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    11
 * This enum defines all possible commands which can be executed to the game
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    12
 * engine. Observing the game like the query-tool or checking the profit of a
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    13
 * vehicle don't result in a command which should be executed in the engine
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    14
 * nor send to the server in a network game.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    15
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    16
 * @see _command_proc_table
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    17
 */
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    18
enum {
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    19
	CMD_BUILD_RAILROAD_TRACK         =   0, ///< build a rail track
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    20
	CMD_REMOVE_RAILROAD_TRACK        =   1, ///< remove a rail track
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    21
	CMD_BUILD_SINGLE_RAIL            =   2, ///< build a single rail track
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    22
	CMD_REMOVE_SINGLE_RAIL           =   3, ///< remove a single rail track
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    23
	CMD_LANDSCAPE_CLEAR              =   4, ///< demolish a tile
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    24
	CMD_BUILD_BRIDGE                 =   5, ///< build a bridge
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    25
	CMD_BUILD_RAILROAD_STATION       =   6, ///< build a railroad station
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    26
	CMD_BUILD_TRAIN_DEPOT            =   7, ///< build a train depot
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    27
	CMD_BUILD_SIGNALS                =   8, ///< build a signal
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    28
	CMD_REMOVE_SIGNALS               =   9, ///< remove a signal
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    29
	CMD_TERRAFORM_LAND               =  10, ///< terraform a tile
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    30
	CMD_PURCHASE_LAND_AREA           =  11, ///< purchase a tile
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    31
	CMD_SELL_LAND_AREA               =  12, ///< sell a bought tile before
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    32
	CMD_BUILD_TUNNEL                 =  13, ///< build a tunnel
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    33
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    34
	CMD_REMOVE_FROM_RAILROAD_STATION =  14, ///< remove a tile station
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    35
	CMD_CONVERT_RAIL                 =  15, ///< convert a rail type
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    36
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    37
	CMD_BUILD_TRAIN_WAYPOINT         =  16, ///< build a waypoint
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    38
	CMD_RENAME_WAYPOINT              =  17, ///< rename a waypoint
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    39
	CMD_REMOVE_TRAIN_WAYPOINT        =  18, ///< remove a waypoint
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    40
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    41
	CMD_BUILD_ROAD_STOP              =  21, ///< build a road stop
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    42
	CMD_REMOVE_ROAD_STOP             =  22, ///< remove a road stop
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    43
	CMD_BUILD_LONG_ROAD              =  23, ///< build a complete road (not a "half" one)
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    44
	CMD_REMOVE_LONG_ROAD             =  24, ///< remove a complete road (not a "half" one)
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    45
	CMD_BUILD_ROAD                   =  25, ///< build a "half" road
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    46
	CMD_REMOVE_ROAD                  =  26, ///< remove a "half" road
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    47
	CMD_BUILD_ROAD_DEPOT             =  27, ///< build a road depot
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    48
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    49
	CMD_BUILD_AIRPORT                =  29, ///< build an airport
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    50
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    51
	CMD_BUILD_DOCK                   =  30, ///< build a dock
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
    52
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    53
	CMD_BUILD_SHIP_DEPOT             =  31, ///< build a ship depot
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    54
	CMD_BUILD_BUOY                   =  32, ///< build a buoy
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    55
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    56
	CMD_PLANT_TREE                   =  33, ///< plant a tree
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    57
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    58
	CMD_BUILD_RAIL_VEHICLE           =  34, ///< build a rail vehicle
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    59
	CMD_MOVE_RAIL_VEHICLE            =  35, ///< move a rail vehicle (in the depot)
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    60
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    61
	CMD_START_STOP_TRAIN             =  36, ///< start or stop a train
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    62
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    63
	CMD_SELL_RAIL_WAGON              =  38, ///< sell a rail wagon
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    64
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    65
	CMD_SEND_TRAIN_TO_DEPOT          =  39, ///< send a train to a depot
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    66
	CMD_FORCE_TRAIN_PROCEED          =  40, ///< proceed a train to pass a red signal
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    67
	CMD_REVERSE_TRAIN_DIRECTION      =  41, ///< turn a train around
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    68
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    69
	CMD_MODIFY_ORDER                 =  42, ///< modify an order (like set full-load)
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    70
	CMD_SKIP_TO_ORDER                =  43, ///< skip an order to the next of specific one
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    71
	CMD_DELETE_ORDER                 =  44, ///< delete an order
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    72
	CMD_INSERT_ORDER                 =  45, ///< insert a new order
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    73
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    74
	CMD_CHANGE_SERVICE_INT           =  46, ///< change the server interval of a vehicle
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    75
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    76
	CMD_BUILD_INDUSTRY               =  47, ///< build a new industry
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    77
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    78
	CMD_BUILD_COMPANY_HQ             =  48, ///< build the company headquarter
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    79
	CMD_SET_PLAYER_FACE              =  49, ///< set the face of the player/company
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    80
	CMD_SET_PLAYER_COLOR             =  50, ///< set the color of the player/company
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    81
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    82
	CMD_INCREASE_LOAN                =  51, ///< increase the loan from the bank
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    83
	CMD_DECREASE_LOAN                =  52, ///< decrease the loan from the bank
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    84
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    85
	CMD_WANT_ENGINE_PREVIEW          =  53, ///< confirm the preview of an engine
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    86
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    87
	CMD_NAME_VEHICLE                 =  54, ///< rename a whole vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    88
	CMD_RENAME_ENGINE                =  55, ///< rename a engine (in the engine list)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    89
	CMD_CHANGE_COMPANY_NAME          =  56, ///< change the company name
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    90
	CMD_CHANGE_PRESIDENT_NAME        =  57, ///< change the president name
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    91
	CMD_RENAME_STATION               =  58, ///< rename a station
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    92
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    93
	CMD_SELL_AIRCRAFT                =  59, ///< sell an aircraft
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    94
	CMD_START_STOP_AIRCRAFT          =  60, ///< start/stop an aircraft
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    95
	CMD_BUILD_AIRCRAFT               =  61, ///< build an aircraft
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    96
	CMD_SEND_AIRCRAFT_TO_HANGAR      =  62, ///< send an aircraft to a hanger
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
    97
	CMD_REFIT_AIRCRAFT               =  64, ///< refit the cargo space of an aircraft
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    98
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
    99
	CMD_PLACE_SIGN                   =  65, ///< place a sign
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   100
	CMD_RENAME_SIGN                  =  66, ///< rename a sign
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   101
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   102
	CMD_BUILD_ROAD_VEH               =  67, ///< build a road vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   103
	CMD_START_STOP_ROADVEH           =  68, ///< start/stop a road vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   104
	CMD_SELL_ROAD_VEH                =  69, ///< sell a road vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   105
	CMD_SEND_ROADVEH_TO_DEPOT        =  70, ///< send a road vehicle to the depot
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   106
	CMD_TURN_ROADVEH                 =  71, ///< turn a road vehicle around
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   107
	CMD_REFIT_ROAD_VEH               =  72, ///< refit the cargo space of a road vehicle
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   108
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   109
	CMD_PAUSE                        =  73, ///< pause the game
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   110
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   111
	CMD_BUY_SHARE_IN_COMPANY         =  74, ///< buy a share from a company
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   112
	CMD_SELL_SHARE_IN_COMPANY        =  75, ///< sell a share from a company
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   113
	CMD_BUY_COMPANY                  =  76, ///< buy a company which is bankrupt
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   114
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   115
	CMD_BUILD_TOWN                   =  77, ///< build a town
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   116
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   117
	CMD_RENAME_TOWN                  =  80, ///< rename a town
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   118
	CMD_DO_TOWN_ACTION               =  81, ///< do a action from the town detail window (like advertises or bribe)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   119
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   120
	CMD_SET_ROAD_DRIVE_SIDE          =  82, ///< set the side where the road vehicles drive
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   121
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   122
	CMD_CHANGE_DIFFICULTY_LEVEL      =  85, ///< change the difficult of a game (each setting for it own)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   123
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   124
	CMD_START_STOP_SHIP              =  86, ///< start/stop a ship
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   125
	CMD_SELL_SHIP                    =  87, ///< sell a ship
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   126
	CMD_BUILD_SHIP                   =  88, ///< build a new ship
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   127
	CMD_SEND_SHIP_TO_DEPOT           =  89, ///< send a ship to a depot
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   128
	CMD_REFIT_SHIP                   =  91, ///< refit the cargo space of a ship
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   129
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   130
	CMD_ORDER_REFIT                  =  98, ///< change the refit informaction of an order (for "goto depot" )
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   131
	CMD_CLONE_ORDER                  =  99, ///< clone (and share) an order
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   132
	CMD_CLEAR_AREA                   = 100, ///< clear an area
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   133
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   134
	CMD_MONEY_CHEAT                  = 102, ///< do the money cheat
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   135
	CMD_BUILD_CANAL                  = 103, ///< build a canal
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
   136
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   137
	CMD_PLAYER_CTRL                  = 104, ///< used in multiplayer to create a new player etc.
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   138
	CMD_LEVEL_LAND                   = 105, ///< level land
4344
7e123fec5b0b (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct.
rubidium
parents: 3990
diff changeset
   139
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   140
	CMD_REFIT_RAIL_VEHICLE           = 106, ///< refit the cargo space of a train
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   141
	CMD_RESTORE_ORDER_INDEX          = 107, ///< restore vehicle order-index and service interval
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   142
	CMD_BUILD_LOCK                   = 108, ///< build a lock
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   143
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   144
	CMD_BUILD_SIGNAL_TRACK           = 110, ///< add signals along a track (by dragging)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   145
	CMD_REMOVE_SIGNAL_TRACK          = 111, ///< remove signals along a track (by dragging)
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   146
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   147
	CMD_GIVE_MONEY                   = 113, ///< give money to an other player
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   148
	CMD_CHANGE_PATCH_SETTING         = 114, ///< change a patch setting
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   149
7560
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   150
	CMD_SET_AUTOREPLACE              = 115, ///< set an autoreplace entry
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   151
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   152
	CMD_CLONE_VEHICLE                = 116, ///< clone a vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   153
	CMD_MASS_START_STOP              = 117, ///< start/stop all vehicles (in a depot)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   154
	CMD_DEPOT_SELL_ALL_VEHICLES      = 118, ///< sell all vehicles which are in a given depot
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   155
	CMD_DEPOT_MASS_AUTOREPLACE       = 119, ///< force the autoreplace to take action in a given depot
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   156
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   157
	CMD_CREATE_GROUP                 = 120, ///< create a new group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   158
	CMD_DELETE_GROUP                 = 121, ///< delete a group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   159
	CMD_RENAME_GROUP                 = 122, ///< rename a group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   160
	CMD_ADD_VEHICLE_GROUP            = 123, ///< add a vehicle to a group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   161
	CMD_ADD_SHARED_VEHICLE_GROUP     = 124, ///< add all other shared vehicles to a group which are missing
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   162
	CMD_REMOVE_ALL_VEHICLES_GROUP    = 125, ///< remove all vehicles from a group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   163
	CMD_SET_GROUP_REPLACE_PROTECTION = 126, ///< set the autoreplace-protection for a group
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   164
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   165
	CMD_MOVE_ORDER                   = 127, ///< move an order
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   166
	CMD_CHANGE_TIMETABLE             = 128, ///< change the timetable for a vehicle
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   167
	CMD_SET_VEHICLE_ON_TIME          = 129, ///< set the vehicle on time feature (timetable)
7f9b639f30af (svn r11085) -Fix-ish (r11084): some tabs that did not show up in the diff, which caused a mess of tab and non-tab usage.
rubidium
parents: 7559
diff changeset
   168
	CMD_AUTOFILL_TIMETABLE           = 130, ///< autofill the timetable
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   169
};
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   170
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   171
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   172
 * List of flags for a command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   173
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   174
 * This enums defines some flags which can be used for the commands.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   175
 */
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   176
enum {
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   177
	DC_EXEC            = 0x01, ///< execute the given command
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   178
	DC_AUTO            = 0x02, ///< don't allow building on structures
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   179
	DC_QUERY_COST      = 0x04, ///< query cost only,  don't build.
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   180
	DC_NO_WATER        = 0x08, ///< don't allow building on water
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   181
	DC_NO_RAIL_OVERLAP = 0x10, ///< don't allow overlap of rails (used in buildrail)
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   182
	DC_AI_BUILDING     = 0x20, ///< special building rules for AI
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   183
	DC_NO_TOWN_RATING  = 0x40, ///< town rating does not disallow you from building
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   184
	DC_FORCETEST       = 0x80, ///< force test too.
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   185
};
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   186
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   187
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   188
 * Used to combine a StringID with the command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   189
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   190
 * This macro can be used to add a StringID (the error message to show) on a command-id
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   191
 * (CMD_xxx). Use the binary or-operator "|" to combine the command with the result from
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   192
 * this macro.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   193
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   194
 * @param x The StringID to combine with a command-id
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   195
 */
6491
00dc414c909d (svn r9672) -Cleanup: lots of coding style fixes around operands.
rubidium
parents: 6248
diff changeset
   196
#define CMD_MSG(x) ((x) << 16)
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   197
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   198
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   199
 * Defines some flags.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   200
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   201
 * This enumeration defines some flags which are binary-or'ed on a command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   202
 */
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   203
enum {
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   204
	CMD_NO_WATER              = 0x0400, ///< dont build on water
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   205
	CMD_NETWORK_COMMAND       = 0x0800, ///< execute the command without sending it on the network
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   206
	CMD_NO_TEST_IF_IN_NETWORK = 0x1000, ///< When enabled, the command will bypass the no-DC_EXEC round if in network
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   207
	CMD_SHOW_NO_ERROR         = 0x2000, ///< do not show the error message
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   208
};
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   209
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   210
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   211
 * Command flags for the command table _command_proc_table.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   212
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   213
 * This enumeration defines flags for the _command_proc_table.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   214
 */
1804
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   215
enum {
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   216
	CMD_SERVER  = 0x1, ///< the command can only be initiated by the server
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   217
	CMD_OFFLINE = 0x2, ///< the command cannot be executed in a multiplayer game; single-player only
7521
0da1e91510e4 (svn r11040) -Fix [FS#1179]: removing CMD_AUTO from some commands could remotely trigger an assertion.
rubidium
parents: 7393
diff changeset
   218
	CMD_AUTO    = 0x4, ///< set the DC_AUTO flag on this command
1804
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   219
};
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   220
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   221
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   222
 * Defines the callback type for all command handler functions.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   223
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   224
 * This type defines the function header for all functions which handles a CMD_* command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   225
 * A command handler use the parameters to act according to the meaning of the command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   226
 * The tile parameter defines the tile to perform an action on.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   227
 * The flag parameter is filled with flags from the DC_* enumeration. The parameters
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   228
 * p1 and p2 are filled with parameters for the command like "which road type", "which
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   229
 * order" or "direction". Each function should mentioned in there doxygen comments
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   230
 * the usage of these parameters.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   231
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   232
 * @param tile The tile to apply a command on
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   233
 * @param flags Flags for the command, from the DC_* enumeration
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   234
 * @param p1 Additional data for the command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   235
 * @param p2 Additional data for the command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   236
 * @return The CommandCost of the command, which can be succeeded or failed.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   237
 */
6943
1914f26aee04 (svn r10197) -Codechange: replace int32 with CommandCost where appropriate.
rubidium
parents: 6832
diff changeset
   238
typedef CommandCost CommandProc(TileIndex tile, uint32 flags, uint32 p1, uint32 p2);
3491
35d747bb5e82 (svn r4342) Change the first two parameters of commands - virtual pixel coordinates of the tile to operate on - to a TileIndex
tron
parents: 2819
diff changeset
   239
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   240
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   241
 * Define a command with the flags which belongs to it.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   242
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   243
 * This struct connect a command handler function with the flags created with
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   244
 * the #CMD_AUTO, #CMD_OFFLINE and #CMD_SERVER values.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   245
 */
6248
e4a2ed7e5613 (svn r9051) -Codechange: typedef [enum|struct] Y {} X; -> [enum|struct] X {};
rubidium
parents: 6247
diff changeset
   246
struct Command {
1804
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   247
	CommandProc *proc;
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   248
	byte flags;
6248
e4a2ed7e5613 (svn r9051) -Codechange: typedef [enum|struct] Y {} X; -> [enum|struct] X {};
rubidium
parents: 6247
diff changeset
   249
};
1804
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   250
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   251
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   252
 * Checks if a command failes.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   253
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   254
 * As you see the parameter is not a command but the return value of a command,
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   255
 * the CommandCost class. This function checks if the command executed by
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   256
 * the CommandProc function failed and returns true if it does.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   257
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   258
 * @param cost The return value of a CommandProc call
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   259
 * @return true if the command failes
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   260
 * @see CmdSucceded
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   261
 */
6950
14ecb0acdfb4 (svn r10205) -Codechange: refactor returning of cost, so it can be more easily modified.
rubidium
parents: 6946
diff changeset
   262
static inline bool CmdFailed(CommandCost cost) { return cost.Failed(); }
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   263
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   264
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   265
 * Checks if a command succeeded.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   266
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   267
 * As #CmdFailed this function checks if a command succeeded
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   268
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   269
 * @param cost The return value of a CommandProc call
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   270
 * @return true if the command succeeded
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   271
 * @see CmdSucceeded
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   272
 */
6950
14ecb0acdfb4 (svn r10205) -Codechange: refactor returning of cost, so it can be more easily modified.
rubidium
parents: 6946
diff changeset
   273
static inline bool CmdSucceeded(CommandCost cost) { return cost.Succeeded(); }
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   274
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   275
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   276
 * Define a default return value for a failed command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   277
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   278
 * This variable contains a CommandCost object with is declared as "failed".
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   279
 * Other functions just need to return this error if there is an error,
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   280
 * which doesn't need to specific by a StringID.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   281
 */
7393
f3d27c82fec3 (svn r10762) -Codechange: Change enum StringIDEnum { to static const StringID = for
peter1138
parents: 7222
diff changeset
   282
static const CommandCost CMD_ERROR = CommandCost(INVALID_STRING_ID);
1691
852ca27d6eef (svn r2195) Add CmdFailed() as the One True Way(tm) to check if a command failed.
tron
parents: 1623
diff changeset
   283
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   284
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   285
 * Returns from a function with a specific StringID as error.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   286
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   287
 * This macro is used to return from a function. The parameter contains the
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   288
 * StringID which will be returned.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   289
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   290
 * @param errcode The StringID to return
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   291
 */
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   292
#define return_cmd_error(errcode) return CommandCost(errcode);
6946
a48b23f1cc8a (svn r10200) -Codechange: add "shortcut" for !CmdFailed (CmdSucceeded).
rubidium
parents: 6943
diff changeset
   293
6123
04eb770ec17e (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style.
belugas
parents: 6012
diff changeset
   294
/* command.cpp */
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   295
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   296
 * Define a callback function for the client, after the command is finished.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   297
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   298
 * Functions of this type are called after the command is finished. The parameters
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   299
 * are from the #CommandProc callback type. The boolean parameter indicates if the
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   300
 * command succeeded or failed.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   301
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   302
 * @param success If the command succeeded or not.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   303
 * @param tile The tile of the command action
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   304
 * @param p1 Additional data of the command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   305
 * @param p1 Additional data of the command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   306
 * @see CommandProc
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   307
 */
4828
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   308
typedef void CommandCallback(bool success, TileIndex tile, uint32 p1, uint32 p2);
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   309
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   310
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   311
 * Execute a command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   312
 */
6943
1914f26aee04 (svn r10197) -Codechange: replace int32 with CommandCost where appropriate.
rubidium
parents: 6832
diff changeset
   313
CommandCost DoCommand(TileIndex tile, uint32 p1, uint32 p2, uint32 flags, uint procc);
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   314
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   315
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   316
 * Execute a network safe DoCommand function
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   317
 */
7222
d46753675bf7 (svn r10501) -Fix [FS#1015]: error dialog was sometimes shown on all clients when a command failed instead of only the client that actually did the command.
rubidium
parents: 7066
diff changeset
   318
bool DoCommandP(TileIndex tile, uint32 p1, uint32 p2, CommandCallback *callback, uint32 cmd, bool my_cmd = true);
4828
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   319
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   320
#ifdef ENABLE_NETWORK
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   321
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   322
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   323
 * Send a command over the network
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   324
 */
4828
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   325
void NetworkSend_Command(TileIndex tile, uint32 p1, uint32 p2, uint32 cmd, CommandCallback *callback);
4e6f53fa10cb (svn r6752) -Codechange: Move command functions from messy functions.h into command.h
Darkvater
parents: 4712
diff changeset
   326
#endif /* ENABLE_NETWORK */
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   327
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   328
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   329
 * Text, which gets sent with a command
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   330
 *
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   331
 * This variable contains a string (be specific a pointer of the first
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   332
 * char of this string) which will be send with a command. This is
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   333
 * used for user input data like names or chat messages.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   334
 */
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   335
extern const char *_cmd_text;
1820
d03c56850dc2 (svn r2324) Introduce _cmd_text for passing strings with a command instead of abusing _decode_parameters as text buffer. This should prevent several possible buffer overruns and is a bit cleaner to use. As bonus it reduces the size of most command packets by 79 bytes.
tron
parents: 1804
diff changeset
   336
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   337
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   338
 * Checks if a integer value belongs to a command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   339
 */
959
e6a3bbda610f (svn r1451) Fix some of the signed/unsigned comparison warnings
tron
parents: 903
diff changeset
   340
bool IsValidCommand(uint cmd);
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   341
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   342
 * Returns the flags from a given command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   343
 */
1804
fbe724472bb4 (svn r2308) - Fix: enforce server-only and/or offline commands by giving them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security"
Darkvater
parents: 1796
diff changeset
   344
byte GetCommandFlags(uint cmd);
7559
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   345
/**
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   346
 * Returns the current money available which can be used for a command.
40d62002dad3 (svn r11084) -Documentation [FS#1219]: of command.*. Patch by Progman.
rubidium
parents: 7521
diff changeset
   347
 */
6990
136a08baf0ed (svn r10246) -Fix (r10297): some forgotten money conversions and truncation issues. Thanks to benc for providing the patch.
rubidium
parents: 6980
diff changeset
   348
Money GetAvailableMoneyForCommand();
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   349
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   350
#endif /* COMMAND_H */