Added some nerfs for the Mars mission in super-easy mode.
This makes mines much less frequent and spreads the asteroids out much more. The other super-easy mode nerfs don't work on Mars, so these custom nerfs are necessary to keep the difficulty consistent.
This commit is contained in:
parent
5e1892235c
commit
b73a56e587
12
src/alien.c
12
src/alien.c
|
@ -1474,8 +1474,16 @@ int alien_place(Object *alien)
|
||||||
|
|
||||||
if (game.area == MISN_MARS)
|
if (game.area == MISN_MARS)
|
||||||
{
|
{
|
||||||
alien->x = screen->w + RANDRANGE(0, 400);
|
if (game.difficulty == DIFFICULTY_SUPEREASY)
|
||||||
alien->y = RANDRANGE(-screen->h / 3, (4 * screen->h) / 3);
|
{
|
||||||
|
alien->x = screen->w + RANDRANGE(0, 1200);
|
||||||
|
alien->y = RANDRANGE(-screen->h, screen->h);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
alien->x = screen->w + RANDRANGE(0, 400);
|
||||||
|
alien->y = RANDRANGE(-screen->h / 3, (4 * screen->h) / 3);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i = 0 ; i < ALIEN_MAX ; i++)
|
for (int i = 0 ; i < ALIEN_MAX ; i++)
|
||||||
|
|
|
@ -2448,6 +2448,8 @@ void game_getDifficultyText(char *dest, int difficulty)
|
||||||
|
|
||||||
int game_mainLoop()
|
int game_mainLoop()
|
||||||
{
|
{
|
||||||
|
float chance;
|
||||||
|
|
||||||
engine_resetLists();
|
engine_resetLists();
|
||||||
|
|
||||||
mission_set(game.area);
|
mission_set(game.area);
|
||||||
|
@ -2774,7 +2776,12 @@ int game_mainLoop()
|
||||||
|
|
||||||
if ((game.area == MISN_MARS) && (engine.addAliens > -1))
|
if ((game.area == MISN_MARS) && (engine.addAliens > -1))
|
||||||
{
|
{
|
||||||
if ((rand() % 5) == 0)
|
if (game.difficulty == DIFFICULTY_SUPEREASY)
|
||||||
|
chance = 1. / 20.;
|
||||||
|
else
|
||||||
|
chance = 1. / 5.;
|
||||||
|
|
||||||
|
if (CHANCE(chance))
|
||||||
// Note: The originally specified range for x was [800, 100],
|
// Note: The originally specified range for x was [800, 100],
|
||||||
// which with the original rrand function caused the result
|
// which with the original rrand function caused the result
|
||||||
// returned to be `800 + rand() % -699`. Clearly a mistake,
|
// returned to be `800 + rand() % -699`. Clearly a mistake,
|
||||||
|
|
|
@ -1186,17 +1186,23 @@ void mission_showStartScreen()
|
||||||
|
|
||||||
if (mission.timeLimit1[0] > 0)
|
if (mission.timeLimit1[0] > 0)
|
||||||
{
|
{
|
||||||
if (game.area != MISN_MARS)
|
if (game.area == MISN_MARS)
|
||||||
{
|
{
|
||||||
/// "%d" must be retained. It is replaced with the mission time
|
snprintf(temp, STRMAX_SHORT, ngettext(
|
||||||
/// limit in minutes.
|
/// "%d" must be retained. It is replaced with the mission required
|
||||||
snprintf(temp, STRMAX_SHORT, _("TIME LIMIT: %d minutes"), mission.timeLimit1[0]);
|
/// survival time in minutes.
|
||||||
|
"SURVIVAL FOR %d minute",
|
||||||
|
"SURVIVAL FOR %d minutes",
|
||||||
|
mission.timeLimit1[0]), mission.timeLimit1[0]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
/// "%d" must be retained. It is replaced with the mission required
|
snprintf(temp, STRMAX_SHORT, ngettext(
|
||||||
/// survival time in minutes.
|
/// "%d" must be retained. It is replaced with the mission time
|
||||||
snprintf(temp, STRMAX_SHORT, _("SURVIVAL FOR %d minutes"), mission.timeLimit1[0]);
|
/// limit in minutes.
|
||||||
|
"TIME LIMIT: %d minute",
|
||||||
|
"TIME LIMIT: %d minutes",
|
||||||
|
mission.timeLimit1[0]), mission.timeLimit1[0]);
|
||||||
}
|
}
|
||||||
screen_renderUnicode(temp, -1, screen->h / 2 + 195, FONT_RED);
|
screen_renderUnicode(temp, -1, screen->h / 2 + 195, FONT_RED);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue