Added a new "original" difficulty.
This difficulty is meant to imitate the original Project: Starfighter as closely as possible, for purists.
This commit is contained in:
parent
7e69ee79ad
commit
e105d6a1cc
|
@ -425,7 +425,7 @@ void doBullets()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((currentGame.difficulty > DIFFICULTY_EASY) &&
|
if ((currentGame.difficulty != DIFFICULTY_EASY) &&
|
||||||
((bullet->owner == &player) || (bullet->id == WT_ROCKET)))
|
((bullet->owner == &player) || (bullet->id == WT_ROCKET)))
|
||||||
{
|
{
|
||||||
for (int j = 0 ; j < 20 ; j++)
|
for (int j = 0 ; j < 20 ; j++)
|
||||||
|
|
|
@ -50,8 +50,9 @@ void addCollectable(float x, float y, int type, int value, int life)
|
||||||
{
|
{
|
||||||
type = P_PLASMA_RATE;
|
type = P_PLASMA_RATE;
|
||||||
|
|
||||||
if ((currentGame.difficulty >= DIFFICULTY_NIGHTMARE) ||
|
if ((currentGame.difficulty == DIFFICULTY_NIGHTMARE) ||
|
||||||
((currentGame.difficulty > DIFFICULTY_EASY) &&
|
((currentGame.difficulty != DIFFICULTY_EASY) &&
|
||||||
|
(currentGame.difficulty != DIFFICULTY_ORIGINAL) &&
|
||||||
((currentGame.area == 5) || (currentGame.area == 11) ||
|
((currentGame.area == 5) || (currentGame.area == 11) ||
|
||||||
(currentGame.area == 18) || (currentGame.area == 25))))
|
(currentGame.area == 18) || (currentGame.area == 25))))
|
||||||
{
|
{
|
||||||
|
|
|
@ -374,10 +374,12 @@ enum {
|
||||||
|
|
||||||
// Difficulties
|
// Difficulties
|
||||||
enum {
|
enum {
|
||||||
DIFFICULTY_EASY,
|
DIFFICULTY_EASY = 0,
|
||||||
DIFFICULTY_NORMAL,
|
DIFFICULTY_NORMAL,
|
||||||
DIFFICULTY_HARD,
|
DIFFICULTY_HARD,
|
||||||
DIFFICULTY_NIGHTMARE
|
DIFFICULTY_NIGHTMARE,
|
||||||
|
DIFFICULTY_ORIGINAL,
|
||||||
|
DIFFICULTY_MAX
|
||||||
};
|
};
|
||||||
|
|
||||||
extern const char *systemNames[];
|
extern const char *systemNames[];
|
||||||
|
|
10
src/game.cpp
10
src/game.cpp
|
@ -106,6 +106,16 @@ void newGame()
|
||||||
player.maxShield = 1;
|
player.maxShield = 1;
|
||||||
currentGame.maxRocketAmmo = 5;
|
currentGame.maxRocketAmmo = 5;
|
||||||
break;
|
break;
|
||||||
|
case DIFFICULTY_ORIGINAL:
|
||||||
|
player.maxShield = 25;
|
||||||
|
|
||||||
|
currentGame.minPlasmaRateLimit = 3;
|
||||||
|
currentGame.minPlasmaDamageLimit = 3;
|
||||||
|
currentGame.minPlasmaOutputLimit = 3;
|
||||||
|
currentGame.maxPlasmaRateLimit = 5;
|
||||||
|
currentGame.maxPlasmaDamageLimit = 5;
|
||||||
|
currentGame.maxPlasmaOutputLimit = 5;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
player.shield = player.maxShield;
|
player.shield = player.maxShield;
|
||||||
|
|
|
@ -527,7 +527,8 @@ int galaxyMap()
|
||||||
signed char saveSlot = -1;
|
signed char saveSlot = -1;
|
||||||
|
|
||||||
// Remove the Supercharge, if it is there
|
// Remove the Supercharge, if it is there
|
||||||
if (currentGame.difficulty > DIFFICULTY_EASY)
|
if ((currentGame.difficulty != DIFFICULTY_EASY) &&
|
||||||
|
(currentGame.difficulty != DIFFICULTY_ORIGINAL))
|
||||||
{
|
{
|
||||||
weapon[W_PLAYER_WEAPON].reload[0] = MAX(
|
weapon[W_PLAYER_WEAPON].reload[0] = MAX(
|
||||||
weapon[W_PLAYER_WEAPON].reload[0],
|
weapon[W_PLAYER_WEAPON].reload[0],
|
||||||
|
|
|
@ -158,6 +158,9 @@ void updateSystemStatus()
|
||||||
currentGame.area = 6;
|
currentGame.area = 6;
|
||||||
strcpy(currentGame.stationedName, "Nerod");
|
strcpy(currentGame.stationedName, "Nerod");
|
||||||
initPlanetMissions(currentGame.system);
|
initPlanetMissions(currentGame.system);
|
||||||
|
|
||||||
|
if (currentGame.difficulty == DIFFICULTY_ORIGINAL)
|
||||||
|
player.maxShield = 50;
|
||||||
}
|
}
|
||||||
else if (currentGame.area == 11)
|
else if (currentGame.area == 11)
|
||||||
{
|
{
|
||||||
|
@ -166,6 +169,9 @@ void updateSystemStatus()
|
||||||
currentGame.area = 12;
|
currentGame.area = 12;
|
||||||
strcpy(currentGame.stationedName, "Odeon");
|
strcpy(currentGame.stationedName, "Odeon");
|
||||||
initPlanetMissions(currentGame.system);
|
initPlanetMissions(currentGame.system);
|
||||||
|
|
||||||
|
if (currentGame.difficulty == DIFFICULTY_ORIGINAL)
|
||||||
|
player.maxShield = 75;
|
||||||
}
|
}
|
||||||
else if (currentGame.area == 18)
|
else if (currentGame.area == 18)
|
||||||
{
|
{
|
||||||
|
@ -174,6 +180,9 @@ void updateSystemStatus()
|
||||||
currentGame.area = 19;
|
currentGame.area = 19;
|
||||||
strcpy(currentGame.stationedName, "Pluto");
|
strcpy(currentGame.stationedName, "Pluto");
|
||||||
initPlanetMissions(currentGame.system);
|
initPlanetMissions(currentGame.system);
|
||||||
|
|
||||||
|
if (currentGame.difficulty == DIFFICULTY_ORIGINAL)
|
||||||
|
player.maxShield = 100;
|
||||||
}
|
}
|
||||||
else // Update the mission for the planet
|
else // Update the mission for the planet
|
||||||
{
|
{
|
||||||
|
|
|
@ -244,7 +244,7 @@ void doPlayer()
|
||||||
player.x = screen->w - xViewBorder;
|
player.x = screen->w - xViewBorder;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else if (currentGame.difficulty != DIFFICULTY_ORIGINAL)
|
||||||
{
|
{
|
||||||
cd = player.x - screen->w / 2;
|
cd = player.x - screen->w / 2;
|
||||||
if (cd < 0)
|
if (cd < 0)
|
||||||
|
@ -273,7 +273,7 @@ void doPlayer()
|
||||||
player.y = screen->h - yViewBorder;
|
player.y = screen->h - yViewBorder;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else if (currentGame.difficulty != DIFFICULTY_ORIGINAL)
|
||||||
{
|
{
|
||||||
cd = player.y - screen->h / 2;
|
cd = player.y - screen->h / 2;
|
||||||
if (cd < 0)
|
if (cd < 0)
|
||||||
|
|
|
@ -73,6 +73,8 @@ static void createDifficultyMenu()
|
||||||
textSurface(TS_DIFFICULTY, "DIFFICULTY - HARD", -1, 370, FONT_WHITE);
|
textSurface(TS_DIFFICULTY, "DIFFICULTY - HARD", -1, 370, FONT_WHITE);
|
||||||
else if (currentGame.difficulty == DIFFICULTY_NIGHTMARE)
|
else if (currentGame.difficulty == DIFFICULTY_NIGHTMARE)
|
||||||
textSurface(TS_DIFFICULTY, "DIFFICULTY - NIGHTMARE!", -1, 370, FONT_WHITE);
|
textSurface(TS_DIFFICULTY, "DIFFICULTY - NIGHTMARE!", -1, 370, FONT_WHITE);
|
||||||
|
else if (currentGame.difficulty == DIFFICULTY_ORIGINAL)
|
||||||
|
textSurface(TS_DIFFICULTY, "DIFFICULTY - ORIGINAL", -1, 370, FONT_WHITE);
|
||||||
else
|
else
|
||||||
textSurface(TS_DIFFICULTY, "DIFFICULTY - NORMAL", -1, 370, FONT_WHITE);
|
textSurface(TS_DIFFICULTY, "DIFFICULTY - NORMAL", -1, 370, FONT_WHITE);
|
||||||
}
|
}
|
||||||
|
@ -430,8 +432,7 @@ int doTitle()
|
||||||
else if (selectedOption == 2)
|
else if (selectedOption == 2)
|
||||||
{
|
{
|
||||||
currentGame.difficulty++;
|
currentGame.difficulty++;
|
||||||
if (currentGame.difficulty > DIFFICULTY_NIGHTMARE)
|
currentGame.difficulty %= DIFFICULTY_MAX;
|
||||||
currentGame.difficulty = DIFFICULTY_EASY;
|
|
||||||
}
|
}
|
||||||
else if (selectedOption == listLength)
|
else if (selectedOption == listLength)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue