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

Function GetTileDesc_Object

src/object_cmd.cpp:661–671  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

659
660
661static void GetTileDesc_Object(TileIndex tile, TileDesc &td)
662{
663 const ObjectSpec *spec = ObjectSpec::GetByTile(tile);
664 td.str = spec->name;
665 td.owner[0] = GetTileOwner(tile);
666 td.build_date = Object::GetByTile(tile)->build_date;
667
668 if (spec->grf_prop.HasGrfFile()) {
669 td.grf = GetGRFConfig(spec->grf_prop.grfid)->GetName();
670 }
671}
672
673static void TileLoop_Object(TileIndex tile)
674{

Callers

nothing calls this directly

Calls 4

GetTileOwnerFunction · 0.85
GetGRFConfigFunction · 0.85
HasGrfFileMethod · 0.80
GetNameMethod · 0.45

Tested by

no test coverage detected