Show disable and kill limit on hud.

This commit is contained in:
Steve 2016-05-10 09:59:21 +01:00
parent 3537265e6a
commit e631133983
1 changed files with 9 additions and 1 deletions

View File

@ -446,7 +446,11 @@ static void drawObjectives(void)
blit(clock, (SCREEN_WIDTH / 2) - 50, 14, 0);
}
if (game.currentMission->challengeData.itemLimit)
if (game.currentMission->challengeData.killLimit)
{
drawText(SCREEN_WIDTH / 2, 35, 14, TA_CENTER, colors.white, "%d / %d", battle.stats[STAT_ENEMIES_KILLED_PLAYER] + battle.stats[STAT_ENEMIES_DISABLED], game.currentMission->challengeData.killLimit);
}
else if (game.currentMission->challengeData.itemLimit)
{
drawText(SCREEN_WIDTH / 2, 35, 14, TA_CENTER, colors.white, "%d / %d", battle.stats[STAT_ITEMS_COLLECTED] + battle.stats[STAT_ITEMS_COLLECTED_PLAYER], game.currentMission->challengeData.itemLimit);
}
@ -458,6 +462,10 @@ static void drawObjectives(void)
{
drawText(SCREEN_WIDTH / 2, 35, 14, TA_CENTER, colors.white, "%d / %d", battle.stats[STAT_CIVILIANS_RESCUED], game.currentMission->challengeData.rescueLimit);
}
else if (game.currentMission->challengeData.disableLimit)
{
drawText(SCREEN_WIDTH / 2, 35, 14, TA_CENTER, colors.white, "%d / %d", battle.stats[STAT_ENEMIES_DISABLED], game.currentMission->challengeData.disableLimit);
}
else if (player->flags & EF_MUST_DISABLE)
{
drawText(SCREEN_WIDTH / 2, 35, 14, TA_CENTER, colors.white, _("System Power : %d%%"), player->systemPower);