Skip to content

Commit db24774

Browse files
committed
Fix handling of unconscious ignored units
Let's assume a 2-stage alien colony mission. When an unconscious unit is left behind on stage 1, while stage 1 is aborted, and all xcom units in stage 2 are killed... the game not only lets the craft survive, but also gives you points for destroying the control center and effectively removes the alien base from geoscape. This is now fixed and mission is considered lost.
1 parent 7f98a69 commit db24774

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎src/Battlescape/DebriefingState.cpp‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -987,6 +987,11 @@ void DebriefingState::prepareDebriefing()
987987
{
988988
playersUnconscious++;
989989
}
990+
else if ((*j)->getStatus() == STATUS_IGNORE_ME && (*j)->getStunlevel() >= (*j)->getHealth())
991+
{
992+
// even for ignored xcom units, we need to know if they're conscious or unconscious
993+
playersUnconscious++;
994+
}
990995
else if ((*j)->isInExitArea(END_POINT))
991996
{
992997
playersInExitArea++;

0 commit comments

Comments
 (0)