| 2031 | } |
| 2032 | |
| 2033 | static int getCurLevelDesignatedCount(color_ostream &out) { |
| 2034 | std::unordered_map<df::coord, df::job *> dig_jobs; |
| 2035 | fill_dig_jobs(dig_jobs); |
| 2036 | |
| 2037 | int count = 0; |
| 2038 | const int z = *window_z; |
| 2039 | for (auto & block : world->map.map_blocks) { |
| 2040 | if (block->map_pos.z != z) |
| 2041 | continue; |
| 2042 | |
| 2043 | const auto & block_pos = block->map_pos; |
| 2044 | for (uint32_t x = 0; x < 16; x++) for (uint32_t y = 0; y < 16; y++) { |
| 2045 | if (!block->designation[x % 16][y % 16].bits.hidden) |
| 2046 | continue; |
| 2047 | df::coord pos = block_pos + df::coord(x, y, 0); |
| 2048 | if (block->designation[x][y].bits.dig || dig_jobs.contains(pos)) |
| 2049 | ++count; |
| 2050 | } |
| 2051 | } |
| 2052 | return count; |
| 2053 | } |
| 2054 | |
| 2055 | static void toggleCurLevelWarmDig(color_ostream &out) { |
| 2056 | toggle_cur_level(out, warm_config); |
nothing calls this directly
no test coverage detected