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

Function unhide_tagged

plugins/dig.cpp:392–412  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

390}
391
392static void unhide_tagged(color_ostream& out, const df::coord & pos) {
393 auto block = Maps::getTileBlock(pos);
394 if (!block)
395 return;
396 if (auto warm_mask = World::getPersistentTilemask(warm_config, block)) {
397 TRACE(log,out).print("testing tile at ({},{},{}); mask:{}, warm:{}\n", pos.x, pos.y, pos.z,
398 warm_mask->getassignment(pos), is_warm(pos));
399 if (warm_mask->getassignment(pos) && is_warm(pos)) {
400 DEBUG(log,out).print("revealing warm dig tile at ({},{},{})\n", pos.x, pos.y, pos.z);
401 block->designation[pos.x&15][pos.y&15].bits.hidden = false;
402 }
403 }
404 if (auto damp_mask = World::getPersistentTilemask(damp_config, block)) {
405 TRACE(log,out).print("testing tile at ({},{},{}); mask:{}, damp:{}\n", pos.x, pos.y, pos.z,
406 damp_mask->getassignment(pos), is_damp(pos));
407 if (damp_mask->getassignment(pos) && is_damp(pos)) {
408 DEBUG(log,out).print("revealing damp dig tile at ({},{},{})\n", pos.x, pos.y, pos.z);
409 block->designation[pos.x&15][pos.y&15].bits.hidden = false;
410 }
411 }
412}
413
414static void unhide_surrounding_tagged_tiles(color_ostream& out, void* job_ptr) {
415 df::job *job = (df::job *)job_ptr;

Callers 1

Calls 4

getTileBlockFunction · 0.85
is_warmFunction · 0.85
is_dampFunction · 0.85
printMethod · 0.45

Tested by

no test coverage detected