MCPcopy Create free account
hub / github.com/DFHack/dfhack / get_track_str

Function get_track_str

plugins/blueprint.cpp:477–487  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

475}
476
477static const char * get_track_str(const char *prefix, df::tiletype tt, df::tile_occupancy occ) {
478 TileDirection tdir = tileDirection(tt);
479
480 string dir;
481 if (tdir.north || occ.bits.carve_track_north) dir += "N";
482 if (tdir.south || occ.bits.carve_track_south) dir += "S";
483 if (tdir.east || occ.bits.carve_track_east) dir += "E";
484 if (tdir.west || occ.bits.carve_track_west) dir += "W";
485
486 return cache(prefix + dir);
487}
488
489static const char * get_tile_carve_minimal(color_ostream &out, const df::coord &pos, const tile_context &) {
490 df::tiletype *tt = Maps::getTileType(pos);

Callers 1

get_tile_carve_minimalFunction · 0.85

Calls 2

tileDirectionFunction · 0.85
cacheFunction · 0.85

Tested by

no test coverage detected