Fixed a bug that caused mobile shields to resurrect the boss from the dead.

The main problem with this bug was simply that it caused a constant
cycle of resurrection and death, which generated tons and tons of
powerups. It was only realistically achievable with cheats enabled,
but still, this seems undesirable.
This commit is contained in:
Julie Marchant 2019-05-26 19:49:28 -04:00
parent 87253b7212
commit 431358e7ae
1 changed files with 4 additions and 2 deletions

View File

@ -1101,7 +1101,9 @@ static void game_doAliens()
aliens[i].dy = 20 + (cosf(barrierLoop + aliens[i].speed) * 40); aliens[i].dy = 20 + (cosf(barrierLoop + aliens[i].speed) * 40);
} }
if (aliens[i].classDef == CD_MOBILESHIELD) if ((aliens[i].classDef == CD_MOBILESHIELD) &&
(aliens[ALIEN_BOSS].active) &&
(aliens[ALIEN_BOSS].shield > 0))
{ {
LIMIT_ADD(aliens[ALIEN_BOSS].shield, 1, 0, LIMIT_ADD(aliens[ALIEN_BOSS].shield, 1, 0,
aliens[ALIEN_BOSS].maxShield); aliens[ALIEN_BOSS].maxShield);