allow semi-wild units to be butchered

develop
Myk Taylor 2023-09-16 19:08:38 -07:00
parent dc270abd0c
commit 48c48baab4
No known key found for this signature in database
2 changed files with 3 additions and 1 deletions

@ -57,6 +57,7 @@ Template for new versions:
## Fixes
- Linux launcher: preserve LD_PRELOAD set by Steam, so Steam Overlay and game streaming works
- `autobutcher`: allow semi-wild units to be butchered again
## Misc Improvements

@ -746,7 +746,8 @@ static bool isInappropriateUnit(df::unit *unit) {
static bool isProtectedUnit(df::unit *unit) {
return Units::isWar(unit) // ignore war dogs etc
|| Units::isHunter(unit) // ignore hunting dogs etc
|| Units::isMarkedForTraining(unit) // ignore units marked for any kind of training
|| Units::isMarkedForWarTraining(unit) // ignore units marked for any kind of training
|| Units::isMarkedForHuntTraining(unit)
// ignore creatures in built cages which are defined as rooms to leave zoos alone
// (TODO: better solution would be to allow some kind of slaughter cages which you can place near the butcher)
|| (isContainedInItem(unit) && isInBuiltCageRoom(unit)) // !!! see comments in isBuiltCageRoom()