From 0ec3df6022b5b999f5371cab0f11eb3991a178f5 Mon Sep 17 00:00:00 2001 From: PatrikLundell Date: Fri, 8 Jun 2018 11:09:11 +0200 Subject: [PATCH] dead/killed flags --- plugins/cursecheck.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/cursecheck.cpp b/plugins/cursecheck.cpp index e006bd17c..4a36f4841 100644 --- a/plugins/cursecheck.cpp +++ b/plugins/cursecheck.cpp @@ -160,8 +160,9 @@ command_result cursecheck (color_ostream &out, vector & parameters) { df::unit * unit = world->units.all[i]; + // filter out all "living" units that are currently removed from play // don't spam all completely dead creatures if not explicitly wanted - if(unit->flags1.bits.dead && ignoreDead) + if((unit->flags1.bits.dead && !unit->flags2.bits.killed) || (unit->flags2.bits.killed && ignoreDead)) { continue; } @@ -217,7 +218,7 @@ command_result cursecheck (color_ostream &out, vector & parameters) cursetype.c_str(), // technically most cursed creatures are undead, // therefore output 'active' if they are not completely dead - unit->flags1.bits.dead ? "deceased" : "active", + unit->flags2.bits.killed ? "deceased" : "active", unit->flags3.bits.ghostly ? "-ghostly" : "", missing ? "-missing" : "" );