diff options
| author | Alexander Gavrilov | 2012-04-10 18:21:19 +0400 |
|---|---|---|
| committer | Alexander Gavrilov | 2012-04-10 18:21:19 +0400 |
| commit | b15d2da819b434f94dc7bd2cd22bbab93c992565 (patch) | |
| tree | 8eee470ad903ccdbcd3a558b54f64a7b69a07316 /plugins/prospector.cpp | |
| parent | 249be0c1a0e267e806a8b0b1342f1f58f53e44fd (diff) | |
| download | dfhack-b15d2da819b434f94dc7bd2cd22bbab93c992565.tar.gz dfhack-b15d2da819b434f94dc7bd2cd22bbab93c992565.tar.bz2 dfhack-b15d2da819b434f94dc7bd2cd22bbab93c992565.tar.xz | |
Get rid of some obsolete api functions, and restructure MapCache.
Diffstat (limited to 'plugins/prospector.cpp')
| -rw-r--r-- | plugins/prospector.cpp | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/plugins/prospector.cpp b/plugins/prospector.cpp index 5afbd2d0..80ce365c 100644 --- a/plugins/prospector.cpp +++ b/plugins/prospector.cpp @@ -426,20 +426,14 @@ command_result prospector (color_ostream &con, vector <string> & parameters) // Get the map block df::coord2d blockCoord(b_x, b_y); MapExtras::Block *b = map.BlockAt(DFHack::DFCoord(b_x, b_y, z)); - if (!b || !b->valid) + if (!b || !b->is_valid()) { continue; } - { // Find features - uint32_t index = b->raw.global_feature; - if (index != -1) - Maps::GetGlobalFeature(blockFeatureGlobal, index); - - index = b->raw.local_feature; - if (index != -1) - Maps::GetLocalFeature(blockFeatureLocal, blockCoord, index); - } + // Find features + b->GetGlobalFeature(&blockFeatureGlobal); + b->GetLocalFeature(&blockFeatureLocal); int global_z = world->map.region_z + z; |
