Commit Graph

134 Commits

Author SHA1 Message Date
Julie Marchant 0bacdfa494 Removed the camera fix for Classic difficulty.
This re-implements the bug where the edge of the screen effectively
slows you down. I might revert this; we'll see.
2019-05-21 13:35:38 -04:00
Julie Marchant e398440a56 Made Classic difficulty almost exactly like the original.
There are only a couple changes that I've left in:

1. On normal missions, the edge of the screen still doesn't slow you down.
2. The shop still does not have the old bug where selling was based on the price of the next item.
3. Not sure about this, but some powerups don't spawn if they're of no use to you; I believe this was not in the original, but it's been left in anyway.
4. Not sure about this either, but I believe the original had the 3-way spread much wider. This has not been adjusted for Classic difficulty.

Other than those three, Classic difficulty is now exactly the same,
including a re-implementation of the whole "score" system where destroying
a ship nets you money instantly and the absurd system where you buy only
10 plasma capacity at a time. I might adjust 1, 3, and/or 4 above later
on.
2019-05-21 13:17:07 -04:00
Julie Marchant e22a2bc168 Converted consts to #define calls. 2019-05-21 01:51:39 -04:00
Julie Marchant 9014be8678 Merge branch 'master' of git.savannah.nongnu.org:/srv/git/starfighter 2019-05-19 23:46:46 -04:00
Julie Marchant 624d5bcb37 Parenthesis 2019-05-19 23:46:26 -04:00
Julie Marchant 8fc30e61f3 Finished conversion to malloc/free. 2019-05-19 18:22:53 -04:00
Julie Marchant 0ba13df0d7 Merge branch 'master' of git.savannah.nongnu.org:/srv/git/starfighter 2019-05-19 13:41:42 -04:00
Julie Marchant 6644be553e Converted some new and delete calls to malloc and free.
This is the last step to converting Starfighter to C. Almost there!
2019-05-19 13:40:50 -04:00
Julie Marchant 5cc48d3f9f Tweaked the reduction method of damageDelay. 2019-05-11 02:26:37 -04:00
Julie Marchant 3b7bb45e28 Improved damaged nerfing
Limited damage prevention to only at the "low" and "critical" levels,
plus added a delay for when damage is first inflicted by rays.

This prevents ships with multiple concentrated shots from having
a disadvantage, and it helps make rays easier to avoid at the same
time (just get out of the ray in time and you don't take damage).
Of course, neither of these apply to Classic difficulty, although
the ray damage delay does apply to Nightmare difficulty (which,
given how unpredictable rays are, I think is quite reasonable).
2019-05-11 02:15:36 -04:00
Julie Marchant ded0be314e Added a damage-control mechanic.
Limits the damage you take somewhat. Basically, this is intended
to prevent sudden deaths; if it doesn't look like you're dying,
you probably won't suddenly get axed. Of course, this is disabled
in Classic difficulty.
2019-05-10 21:09:34 -04:00
onpon4 6c616bb4a2 Fixed where mines appear when screen width is larger than 800.
This causes the game to be easier, but whatever. The game is easier
with a bigger view anyway.
2017-02-05 17:37:22 -05:00
onpon4 aa8ab90cf4 Fixed some minor cosmetic issues. 2017-02-05 14:49:43 -05:00
onpon4 2a032005d1 Some cleanup. 2017-01-26 23:05:21 -05:00
onpon4 d6f29b71b3 Don't resume the music when you press Escape during pause. 2017-01-26 22:41:59 -05:00
onpon4 788ee5eae4 Finished removing Starfighter.h. 2017-01-25 10:48:29 -05:00
onpon4 d6b31a270c More cleanup, updated copyright notices. 2017-01-21 23:55:54 -05:00
onpon4 08b68ab894 Lots more cleanup. 2017-01-20 23:48:53 -05:00
onpon4 dd4e0b3855 Fixed failure to display proper powerup messages in Classic difficulty. 2016-11-26 13:08:53 -05:00
onpon4 1ba51f0e58 Moved most structs to the modules they obviously belong to.
The ones with names that don't correspond to modules and are used
in multiple places have been left alone.
2016-11-25 18:35:25 -05:00
onpon4 d336bb2c83 More cleanup. 2016-11-25 18:21:31 -05:00
onpon4 60ed5cbd65 More cleanup.
It looks like I'm finally almost done with this! The only thing left
is gradually replacing "Starfighter.h" imports with imports of what
actually is needed.
2016-11-25 18:01:36 -05:00
onpon4 b43c52dc23 More cleanup. 2016-11-25 17:10:08 -05:00
onpon4 5b4fa64360 Tweaked the way the laser is handled.
The tweak causes you to be able to fire the laser for more time,
but the difference is subtle (112 frames instead of 100 frames).
2016-11-25 14:36:56 -05:00
onpon4 1be0fd1164 Lots of cleanup done on how weapons are handled.
I did one structural change to the way ship_fireBullet works. It
previously had two separate places for reducing ammo from the player.
I changed this so that it removes ammo in the same place regardless
of which weapon it is, but then performs the plasma "out of ammo"
action afterwards. It seems to work properly.

Also fixed a flaw in the saving which would in some cases cause
the stationed planet to not get saved properly.
2016-11-25 13:50:16 -05:00
onpon4 3400ff180c Renamed "currentMission" to "mission". 2016-11-25 12:53:53 -05:00
onpon4 dc7209164a Renamed the "object" and "collectables" structs.
This was done with "replace all" actions, but I have checked and
the only collatoral damage has been to capitalize some instances
of "objective" in comments.
2016-11-25 12:37:26 -05:00
onpon4 de1cd7c674 Cleaned up the "missions" module, renamed to "mission". 2016-11-25 12:29:15 -05:00
onpon4 aec30bbc3d Reorganized "misc.cpp".
Most functions have been placed into "info.cpp" and "radio.cpp",
while one has been placed into "engine.cpp".
2016-11-22 21:16:49 -05:00
onpon4 30b05b6b4e Replaced all bools with ints.
This is part of the conversion of Starfighter's code to C. C doesn't
have the bool type.
2016-11-19 11:43:50 -05:00
onpon4 e0cac7850c Converted the "missfire" messages. Deleted the now empty messages.cpp. 2016-11-19 08:51:26 -05:00
onpon4 7afd322a71 Some tweaks to prevent silent errors. 2016-11-19 08:34:28 -05:00
onpon4 e9330907b7 Reconstructed player hit messages. 2016-11-19 08:24:12 -05:00
onpon4 7578f3814f Removed the death messages.
At first I was doing the same thing to them I did to the bragging
messages, but when it came to actually thinking of things these
characters should say, nothing I liked came up. The main problem
is nothing fits the characters' expressions. Add to that the
complexity of making this really work right, and it's just not
worth it.

The Sid death message has also been removed, both for consistency
and because of the mismatch of Chris's face with what he said there.
2016-11-19 08:10:25 -05:00
onpon4 063020df22 More cleanup. 2016-11-16 19:43:03 -05:00
onpon4 59088cce0c Make mines simply disappear when they time out rather than exploding.
The explosions of mines off in the distance are extremely annoying in
the Mars mission, in particular. There's no real point in them
doing a timed off-screen explosion, anyway; if they just disappear,
the player won't notice.
2016-01-13 16:09:06 -05:00
onpon4 0929abf3a3 Added a Y component to audio_playSound, and reduction of volume by distance.
This makes it possible to remove code that made mines that exploded
off-screen completely inaudible.
2016-01-10 23:56:26 -05:00
onpon4 6c52a63bc3 Removed the code that caused you to briefly stop when you finished Ellesh.
This was just really weird-looking and had no particular benefit.
I guess theoretically you can use the couple of seconds to grab stuff
you missed, but in practice, there usually isn't much stuff there.
2016-01-08 16:56:07 -05:00
onpon4 0fb6e85eb6 Changed the target in the Poswic mission to Sid.
Sure, the escort is what you're supposedly after, but it's
invincible, and your real priority is to protect Sid. It helps that
it now says "Sid" when Sid is the target; that should prevent
any possible confusion. :)
2016-01-08 16:43:41 -05:00
onpon4 75029e45ee Fixed being able to get hurt after the mission is over.
There were two problems:

1. Some areas did not have any code to protect against this.

2. In one area that did have such code, it was malformed, and actually
   caused the "no damage" cheat to be negated after the mission was
   completed.

Both have been fixed.
2016-01-08 16:36:20 -05:00
onpon4 62d14c57f0 Added special target text for Kline. 2016-01-08 11:09:13 -05:00
onpon4 f8e23ab061 Added special target text when Sid or Phoebe is the target.
This is because it may not be obvious that Sid or Phoebe is the
target now that the indicator for them says their names.
2016-01-08 10:52:34 -05:00
onpon4 efc2311f7a Added special indicators for Sid, Phoebe, and Ursula. 2016-01-08 10:31:01 -05:00
onpon4 401a306793 Added green versions of arrows for friendly ships. 2016-01-08 09:39:12 -05:00
onpon4 79bbe56849 Replaced the previous arrow positioning with a more simplistic one.
The previous one positioned the arrows based on the difference between
their X distance and Y distance; objects that were further away
would be closer to the center. However, the code was confusing, and
a major practical effect of this was it was impossible to really know
exactly where an object was.

This new, simpler method makes aiming at targets that are off-screen
feasible, and it also utilizes the diagonal arrows.
2016-01-08 09:12:07 -05:00
onpon4 33a92b2294 Removed the code that actively prevented the "Target" text from showing.
It was triggered whenever there was a message being displayed.
Thing is, there's no legitimate reason to do this. It doesn't ever
obscure the radio message, and there wasn't some technical limitation
in place. It just did it... just because.
2016-01-07 23:15:01 -05:00
onpon4 e7abfe30a6 Fixed the bug that caused mobile rays to shoot bullets.
This was a strange cause, and I wonder why it happened. Quite simply,
there was an assumption in the code that any alien's primary weapon
was a bullet, despite the fact that the secondary weapon code could
handle any weapon, including bullets. I've fixed this by getting rid
of the special primary weapon mechanism; the one for the secondary
weapons is used on primary weapons as well.
2016-01-07 19:01:25 -05:00
onpon4 6dad38bd20 Made powerups in Classic difficulty behave the same as the original.
There are two aspects to this:

1. They now simply make sure your plasma ammo is at a minimum of
   50, rather than adding to your plasma ammo as in the other
   difficulties.

2. Added a simulation of a bug in Starfighter 1.1 which caused
   each aspect of the Supercharge to be lost when you picked up
   a different associated powerup. Even though this was a bug,
   without it, the Supercharge becomes extraordinarily more
   game-breaking, since it's the only thing that sort of limits
   its longevity.
2016-01-07 06:44:03 -05:00
onpon4 f7aab48a56 Revert "Added usage of plasma ammo by the charger cannon."
This reverts commit 05e645aeff.
2016-01-07 05:36:49 -05:00
onpon4 05e645aeff Added usage of plasma ammo by the charger cannon.
This should add some much-needed depth to the tacticality of the
weapon. It's not much: it takes 5 plasma cells to fully charge the
cannon. But it does eliminate the previous effect where the charger
was always preferable over plasma bullets; it's still preferable in
a lot of circumstances, but for smaller ships, it's now typically
better to use plain old plasma ammo. It also limits the amount of
times the charger can be used.
2016-01-06 21:56:53 -05:00