# cargotype.h File Reference

`#include "cargo_type.h"`
`#include "gfx_type.h"`
`#include "newgrf_string_type.h"`

Go to the source code of this file.

## Data Structures
struct | CargoSpec
## Typedefs
typedef uint32 | CargoLabel
## Enumerations
enum | TownEffect { TE_NONE, TE_PASSENGERS, TE_MAIL, TE_GOODS, TE_WATER, TE_FOOD }
## Functions
void | SetupCargoForClimate (LandscapeID l)
const CargoSpec * | GetCargo (CargoID c)
CargoID | GetCargoIDByLabel (CargoLabel cl)
CargoID | GetCargoIDByBitnum (uint8 bitnum)
| Find the CargoID of a 'bitnum' value.
static bool | IsCargoInClass (CargoID c, uint16 cc)
## Variables
uint32 | _cargo_mask
CargoSpec | _cargo [NUM_CARGO]

## Detailed Description

Definition in file cargotype.h.

## Function Documentation

CargoID GetCargoIDByBitnum | ( | uint8 | bitnum | ) |

Find the CargoID of a 'bitnum' value.

Parameters:

  | bitnum | 'bitnum' to find.

Returns:
  First CargoID with the given bitnum, or CT_INVALID if not found.

Definition at line 88 of file cargotype.cpp.