Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ Template for new versions:

## Fixes
- several fixes related to changes in file system handling in DF 52.01
- `dig-now`: don't allow UNDIGGABLE stones to be excavated

## Misc Improvements
- `autoclothing`: added a ``clear`` option to unset previously set orders
Expand Down
10 changes: 4 additions & 6 deletions plugins/dig-now.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -450,12 +450,10 @@ static bool is_diggable(MapExtras::MapCache &map, const DFCoord &pos,
break;
}

if (mat == df::tiletype_material::FEATURE) {
// adamantine is the only is diggable feature
t_feature feature;
return map.BlockAtTile(pos)->GetLocalFeature(&feature)
&& feature.type == feature_type::deep_special_tube;
}
MaterialInfo mi;
mi.decode(map.baseMaterialAt(pos));
if (mi.material != nullptr && mi.material->flags.is_set(df::material_flags::UNDIGGABLE))
return false;

return true;
}
Expand Down