diff --git a/src/galaxy/starSystems.c b/src/galaxy/starSystems.c index 31ab749..3b6c822 100644 --- a/src/galaxy/starSystems.c +++ b/src/galaxy/starSystems.c @@ -147,7 +147,16 @@ void updateStarSystemMissions(void) if (starSystem->type == SS_NORMAL && !mission->isOptional) { game.totalMissions++; - game.completedMissions++; + } + + if (mission->completed) + { + starSystem->completedMissions++; + + if (starSystem->type == SS_NORMAL && !mission->isOptional) + { + game.completedMissions++; + } } } } @@ -164,19 +173,15 @@ void updateStarSystemMissions(void) { starSystem->availableMissions++; - if (mission->completed) - { - starSystem->completedMissions++; - } - else - { - starSystem->activeMission = mission; - } - if (starSystem->type == SS_NORMAL && !mission->isOptional) { game.availableMissions++; } + + if (!mission->completed) + { + starSystem->activeMission = mission; + } } prev = mission;