|
OpenTTD Source
14.0-beta1
|
Go to the documentation of this file.
128 typedef bool ClickTileProc(
TileIndex tile);
129 typedef void AnimateTileProc(
TileIndex tile);
130 typedef void TileLoopProc(
TileIndex tile);
161 ClearTileProc *clear_tile_proc;
166 AnimateTileProc *animate_tile_proc;
167 TileLoopProc *tile_loop_proc;
168 ChangeTileOwnerProc *change_tile_owner_proc;
171 GetFoundationProc *get_foundation_proc;
182 inline void AddAcceptedCargo(
TileIndex tile,
CargoArray &acceptance, CargoTypes *always_accepted)
185 if (proc ==
nullptr)
return;
186 CargoTypes dummy = 0;
187 proc(tile, acceptance, always_accepted ==
nullptr ? &dummy : always_accepted);
193 if (proc ==
nullptr)
return;
194 proc(tile, produced);
200 assert(proc !=
nullptr);
207 if (proc ==
nullptr)
return false;
@ VETS_STATION_ID_OFFSET
Shift the VehicleEnterTileStatus this many bits to the right to get the station ID when VETS_ENTERED_...
StringID airport_class
Name of the airport class.
int GetSlopeZProc(TileIndex tile, uint x, uint y, bool ground_vehicle)
Tile callback function signature for obtaining the world Z coordinate of a given point of a tile.
const char * grf
newGRF used for the tile contents
@ VETSB_CANNOT_ENTER
The vehicle cannot enter the tile.
Tile information, used while rendering the tile.
StringID railtype
Type of rail on the tile.
Owner owner[4]
Name of the owner(s)
uint32_t StringID
Numeric value that represents a string, independent of the selected language.
void ChangeTileOwner(TileIndex tile, Owner old_owner, Owner new_owner)
Change the owner of a tile.
StringID station_class
Class of station.
uint16_t road_speed
Speed limit of road (bridges and track)
Class for storing amounts of cargo.
@ VETSB_CONTINUE
Bit sets of the above specified bits.
ClickTileProc * click_tile_proc
Called when tile is clicked.
GetTileTrackStatusProc * get_tile_track_status_proc
Get available tracks and status of a tile.
int y
Y position of the tile in unit coordinates.
StringID airport_tile_name
Name of the airport tile.
@ VETS_ENTERED_STATION
The vehicle entered a station.
Owner
Enum for all companies/owners.
DrawTileProc * draw_tile_proc
Called to render the tile and its contents to the screen.
Tile description for the 'land area information' tool.
StringID airport_name
Name of the airport.
DoCommandFlag
List of flags for a command.
Foundation
Enumeration for Foundations.
AddProducedCargoProc * add_produced_cargo_proc
Adds produced cargo of the tile to cargo array supplied as parameter.
Slope tileh
Slope of the tile.
static debug_inline TileType GetTileType(Tile tile)
Get the tiletype of a given tile.
TimerGameCalendar::Date build_date
Date of construction of tile contents.
Slope
Enumeration for the slope-type.
void DrawTileProc(TileInfo *ti)
Tile callback function signature for drawing a tile and its contents to the screen.
Common return value for all commands.
StringID roadtype
Type of road on the tile.
TransportType
Available types of transport.
@ VETS_CANNOT_ENTER
The vehicle cannot enter the tile.
void AddAcceptedCargoProc(TileIndex tile, CargoArray &acceptance, CargoTypes *always_accepted)
Tile callback function signature for obtaining cargo acceptance of a tile.
AddAcceptedCargoProc * add_accepted_cargo_proc
Adds accepted cargo of the tile to cargo array supplied as parameter.
TrackStatus GetTileTrackStatusProc(TileIndex tile, TransportType mode, uint sub_mode, DiagDirection side)
Tile callback function signature for getting the possible tracks that can be taken on a given tile by...
VehicleEnterTileStatus VehicleEnterTile(Vehicle *v, TileIndex tile, int x, int y)
Call the tile callback function for a vehicle entering a tile.
GetTileDescProc * get_tile_desc_proc
Get a description of a tile (for the 'land area information' tool)
@ INVALID_DIAGDIR
Flag for an invalid DiagDirection.
StringID station_name
Type of station within the class.
DiagDirection
Enumeration for diagonal directions.
Set of callback functions for performing tile operations of a given tile type.
TerraformTileProc * terraform_tile_proc
Called when a terraforming operation is about to take place.
uint16_t tram_speed
Speed limit of tram (bridges and track)
void AddProducedCargoProc(TileIndex tile, CargoArray &produced)
Tile callback function signature for obtaining the produced cargo of a tile.
CommandCost TerraformTileProc(TileIndex tile, DoCommandFlag flags, int z_new, Slope tileh_new)
Tile callback function signature of the terraforming callback.
VehicleEnterTileStatus VehicleEnterTileProc(Vehicle *v, TileIndex tile, int x, int y)
uint64_t dparam
Parameter of the str string.
StringID str
Description of the tile.
TrackStatus GetTileTrackStatus(TileIndex tile, TransportType mode, uint sub_mode, DiagDirection side=INVALID_DIAGDIR)
Returns information about trackdirs and signal states.
DECLARE_ENUM_AS_BIT_SET(GenderEthnicity) enum CompanyManagerFaceVariable
Bitgroups of the CompanyManagerFace variable.
@ VETSB_ENTERED_STATION
The vehicle entered a station.
StringID owner_type[4]
Type of each owner.
int x
X position of the tile in unit coordinates.
TileIndex tile
Tile index.
uint16_t rail_speed
Speed limit of rail (bridges and track)
void GetTileDescProc(TileIndex tile, TileDesc *td)
Tile callback function signature for obtaining a tile description.
StringID tramtype
Type of tram on the tile.
const TileTypeProcs *const _tile_type_procs[16]
Tile callback functions for each type of tile.
VehicleEnterTileStatus
The returned bits of VehicleEnterTile.
@ VETSB_ENTERED_WORMHOLE
The vehicle either entered a bridge, tunnel or depot tile (this includes the last tile of the bridge/...
VehicleEnterTileProc * vehicle_enter_tile_proc
Called when a vehicle enters a tile.
@ VETS_ENTERED_WORMHOLE
The vehicle either entered a bridge, tunnel or depot tile (this includes the last tile of the bridge/...