NML:Disable items

From GRFSpecs
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Block Syntax

With a disable_item statement, it's possible to disable one or more existing items. This works for vehicles, houses, industries, cargos and airports. The general syntax is:

disable_item(feature[, first_id[, last_id]]);

feature specifies the feature of the item(s) to disable. If no further arguments are given, all default items of that feature are disabled. If one more argument (first_id) is given, only that ID is disabled. With two more arguments, all items from first_id up to and including last_id are disabled. For lists of default IDs, consult the documentation about that feature. An example:

 /* disable all monorail and maglev vehicles */
 disable_item(FEAT_TRAINS, 54, 115);