diff --git a/data/trophies/trophies.json b/data/trophies/trophies.json index db60bd0..b7a8d74 100644 --- a/data/trophies/trophies.json +++ b/data/trophies/trophies.json @@ -138,6 +138,12 @@ "description" : "Complete a mission using a Shuttle", "value" : "TROPHY_BRONZE" }, + { + "id" : "TEAM_PLAYER", + "title" : "Taking one for the Team", + "description" : "Be killed by a missile that was meant for someone else", + "value" : "TROPHY_SILVER" + }, { "id" : "CHALLENGE_25", "title" : "", diff --git a/src/battle/bullets.c b/src/battle/bullets.c index 8c2c3da..3be3712 100644 --- a/src/battle/bullets.c +++ b/src/battle/bullets.c @@ -214,6 +214,11 @@ static void checkCollisions(Bullet *b) } e->killedBy = b->owner; + + if (b->type == BT_MISSILE && e == player && b->target != player) + { + awardTrophy("TEAM_PLAYER"); + } } if (b->owner == player && b->type == BT_MISSILE)