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

Function get_depot_coords

plugins/pathable.cpp:146–156  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144}
145
146static bool get_depot_coords(color_ostream &out, unordered_set<df::coord> * depot_coords) {
147 CHECK_NULL_POINTER(depot_coords);
148
149 depot_coords->clear();
150 for (auto bld : world->buildings.other.TRADE_DEPOT){
151 DEBUG(log,out).print("found depot at ({}, {}, {})\n", bld->centerx, bld->centery, bld->z);
152 depot_coords->emplace(bld->centerx, bld->centery, bld->z);
153 }
154
155 return !depot_coords->empty();
156}
157
158static bool get_pathability_groups(color_ostream &out, unordered_set<uint16_t> * depot_pathability_groups,
159 const unordered_set<df::coord> & depot_coords)

Callers 2

Calls 3

clearMethod · 0.45
printMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected