MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / Index

Method Index

src/road.cpp:30–36  ·  view source on GitHub ↗

* Get the RoadType for this RoadTypeInfo. * @return RoadType in static RoadTypeInfo definitions. */

Source from the content-addressed store, hash-verified

28 * @return RoadType in static RoadTypeInfo definitions.
29 */
30RoadType RoadTypeInfo::Index() const
31{
32 extern RoadTypeInfo _roadtypes[ROADTYPE_END];
33 size_t index = this - _roadtypes;
34 assert(index < ROADTYPE_END);
35 return static_cast<RoadType>(index);
36}
37
38/**
39 * Return if the tile is a valid tile for a crossing.

Callers 15

GetVariableMethod · 0.45
AllocateMethod · 0.45
BuildCargoTranslationMapFunction · 0.45
CalculateRefitMasksFunction · 0.45
InitRailTypesFunction · 0.45
AllocateRailTypeFunction · 0.45
GetIfNewStopsByTypeFunction · 0.45
FormatStringFunction · 0.45
GetRoadTypeByLabelFunction · 0.45
OnClickMethod · 0.45
DrawWidgetMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected