diff --git a/src/battle/bullets.c b/src/battle/bullets.c index acc7f9c..b080181 100644 --- a/src/battle/bullets.c +++ b/src/battle/bullets.c @@ -205,16 +205,8 @@ static void checkCollisions(Bullet *b) } /* assuming that health <= 0 will always mean killed */ - if (e->health <= 0 && b->owner == player && (!(e->flags & EF_NO_KILL_INC))) + if (e->health <= 0) { - battle.stats[STAT_ENEMIES_KILLED_PLAYER]++; - battle.stats[STAT_EPIC_KILL_STREAK]++; - - if (e->side == SIDE_PANDORAN) - { - awardTrophy("PANDORAN"); - } - e->killedBy = b->owner; if (b->type == BT_MISSILE && e == player && b->target != player) diff --git a/src/battle/fighters.c b/src/battle/fighters.c index be3a362..2cd1459 100644 --- a/src/battle/fighters.c +++ b/src/battle/fighters.c @@ -530,6 +530,11 @@ static void die(void) { battle.stats[STAT_EPIC_KILL_STREAK]++; } + + if (self->side == SIDE_PANDORAN) + { + awardTrophy("PANDORAN"); + } } } diff --git a/src/battle/fighters.h b/src/battle/fighters.h index 144973a..c263834 100644 --- a/src/battle/fighters.h +++ b/src/battle/fighters.h @@ -49,6 +49,7 @@ extern char *getTranslatedString(char *string); extern int getJSONValue(cJSON *node, char *name, int defValue); extern char **toTypeArray(char *types, int *numTypes); extern char *getJSONValueStr(cJSON *node, char *name, char *defValue); +extern void awardTrophy(char *id); extern App app; extern Battle battle;