Prevent player from moving if system power <= 0.
This commit is contained in:
parent
86e0443067
commit
f51557f801
|
@ -93,7 +93,7 @@ void doPlayer(void)
|
||||||
battle.boostTimer = MIN(battle.boostTimer + 1, BOOST_RECHARGE_TIME);
|
battle.boostTimer = MIN(battle.boostTimer + 1, BOOST_RECHARGE_TIME);
|
||||||
battle.ecmTimer = MIN(battle.ecmTimer + 1, ECM_RECHARGE_TIME);
|
battle.ecmTimer = MIN(battle.ecmTimer + 1, ECM_RECHARGE_TIME);
|
||||||
|
|
||||||
if (player->alive == ALIVE_ALIVE)
|
if (player->alive == ALIVE_ALIVE && player->systemPower > 0)
|
||||||
{
|
{
|
||||||
self = player;
|
self = player;
|
||||||
|
|
||||||
|
@ -142,16 +142,6 @@ void doPlayer(void)
|
||||||
initPlayerSelect();
|
initPlayerSelect();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* really only used in challenge mode */
|
|
||||||
if (player->systemPower <= 0 && battle.status == MS_IN_PROGRESS)
|
|
||||||
{
|
|
||||||
if (game.currentMission->challengeData.isChallenge)
|
|
||||||
{
|
|
||||||
addHudMessage(colors.red, _("Challenge Failed!"));
|
|
||||||
failMission();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (battle.status == MS_IN_PROGRESS)
|
if (battle.status == MS_IN_PROGRESS)
|
||||||
{
|
{
|
||||||
|
@ -163,6 +153,16 @@ void doPlayer(void)
|
||||||
player->missiles = 999;
|
player->missiles = 999;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* really only used in challenge mode */
|
||||||
|
if (player->systemPower <= 0 && battle.status == MS_IN_PROGRESS)
|
||||||
|
{
|
||||||
|
if (game.currentMission->challengeData.isChallenge)
|
||||||
|
{
|
||||||
|
addHudMessage(colors.red, _("Challenge Failed!"));
|
||||||
|
failMission();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (battle.boostTimer == (int)BOOST_FINISHED_TIME)
|
if (battle.boostTimer == (int)BOOST_FINISHED_TIME)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue