diff --git a/data/fighters/ataf.json b/data/fighters/ataf.json index 1bb36dc..90ced4a 100644 --- a/data/fighters/ataf.json +++ b/data/fighters/ataf.json @@ -1,9 +1,9 @@ { "name" : "ATAF", "health" : 50, - "shield" : 9999, + "shield" : 1250, "speed" : 2.5, - "reloadTime" : 6, + "reloadTime" : 9, "shieldRechargeRate" : 5, "textureName" : "gfx/fighters/ataf.png", "guns" : [ diff --git a/data/fighters/nymph.json b/data/fighters/nymph.json index 3dfbb08..1f2219a 100644 --- a/data/fighters/nymph.json +++ b/data/fighters/nymph.json @@ -2,7 +2,7 @@ "name" : "Nymph", "health" : 30, "shield" : 25, - "speed" : 2.5, + "speed" : 2.1, "reloadTime" : 14, "shieldRechargeRate" : 30, "textureName" : "gfx/fighters/nymph.png", diff --git a/data/missions/coyote/01 - coyote assault #1.json b/data/missions/coyote/01 - coyote assault #1.json index 15259ef..bcf5f93 100644 --- a/data/missions/coyote/01 - coyote assault #1.json +++ b/data/missions/coyote/01 - coyote assault #1.json @@ -13,19 +13,13 @@ "targetType" : "TT_DESTROY" }, { - "description" : "Do not lose any of the ATAFs", + "description" : "Do not lose any team mates", "targetName" : "ATAF", "targetValue" : 1, "targetType" : "TT_DESTROY", "isCondition" : 1 } ], - "challenges" : [ - { - "type" : "CHALLENGE_NO_LOSSES", - "targetValue" : 0 - } - ], "player" : { "type" : "ATAF", "side" : "SIDE_ALLIES", @@ -33,6 +27,14 @@ "squadron" : "White Knights" }, "fighterGroups" : [ + { + "name" : "ATAF", + "types" : "ATAF", + "number" : 4, + "side" : "SIDE_ALLIES", + "x" : 0, + "y" : 0 + }, { "name" : "Pandoran", "types" : "Jackal;Sphinx;Nymph", diff --git a/manual/index.html b/manual/index.html index 3cbc6c6..4027bad 100644 --- a/manual/index.html +++ b/manual/index.html @@ -1,22 +1,44 @@ + + +TBFTSS - The Pandoran War +

The Battle for the Solar System

The Pandoran War

Introduction

-The Battle for the Solar System - The Pandoran War is a 2D space shooter, based on the space opera novels by Stephen J Sweeney. +The Battle for the Solar System - The Pandoran War is a 2D space shooter, based on the space opera novels by Stephen J Sweeney.

Note: this game is still under heavy development and will feature bugs, incomplete sections, and a numerous other issues until it reaches v1.0. Likewise, this gameplay manually will evolve over time, to become more detailed and helpful.

-

Galactic Map

+

Title Screen

-This is the main mission select screen. Here, you can move around and select star systems in which to undertake missions. Star Systems that have missions will emit red circles at regular intervals. Yellow circles will be emitted by star systems that have no active missions, but still have challenges that can be attempted. +This is the first screen that you will see upon starting the game. You may select from the following options: +

-

Controls

- +

Galactic Map

+

+This is the main mission select screen. Here, you can move around and select star systems in which to undertake missions. Star Systems that have missions will emit red circles at regular intervals. Yellow circles will be emitted by star systems that have no active missions, but still have challenges that can be attempted. Green circles will emit from system that have missions and changes that are 100% completed. You may replay any of these missions, at any time. +

+ +

Controls

+
@@ -28,7 +50,7 @@ The Star System view shows a list of missions available for that star system. Mi

Controls

-
Arrow keysScroll galactic map
ReturnSelect Star System
EscapeMenu
+
@@ -40,17 +62,41 @@ Each mission has various objectives that the player must finish in order to comp

Controls

-
Arrow keysScroll galactic map
ReturnSelect Star System
EscapeMenu
+
+
Left arrowRotate anti-clockwise
Right arrowRotate clockwise
Up arrowAccelerate
Down arrowDecelerate
Left controlFire main cannons
Left shiftSwitch main cannons
ReturnLaunch missile
TabDisplay objectives
EscapeMenu
+

+Most craft are equipped with offensive weaponry, with some fighters featuring more than one type of gun. +

+

+ +

Options

+

+Various game options can be changed: +

+

[1] - changes to this option will take effect next time you start the game.

+

+

About

This game is based on the Battle for the Solar System novel trilogy by Stephen J Sweeney. You can learn more about the trilogy by visiting: @@ -58,7 +104,13 @@ This game is based on the Battle for the Solar System novel trilogy by Stephen J

www.battleforthesolarsystem.com

-

The Battle for the Solar System and related related materials are Copyright ©2009-2015, Stephen J Sweeney. All Rights Reserved.

+

The Battle for the Solar System and related related materials are Copyright ©2009-2015, Stephen J Sweeney. All Rights Reserved.

+ +

License

+ +

+See the LICENSE and README.md files that came with this game for information on the various copyrights of the source code, graphics, sound, and data. Additionally, you may visit https://github.com/stephenjsweeney/tbftss to get the source code itself, and view the files there. +

diff --git a/src/battle/hud.c b/src/battle/hud.c index bc9a8ff..40cef5a 100644 --- a/src/battle/hud.c +++ b/src/battle/hud.c @@ -22,8 +22,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. static void drawHealthShieldBar(int current, int max, int x, int y, int r, int g, int b); static void drawPlayerTargeter(void); -static void drawNumAllies(void); -static void drawNumEnemies(void); +static void drawNumFighters(void); static void drawHealthBars(void); static void drawWeaponInfo(void); static void drawObjectives(void); @@ -35,7 +34,7 @@ static HudMessage *hudMessageTail; static SDL_Texture *targetPointer; static SDL_Texture *targetCircle; static SDL_Texture *smallFighter; - +static int numMessages; static int healthWarning; static char *gunName[] = {"", "Particle Cannon", "Plasma Cannon", "Laser Cannon", "Mag Cannon"}; @@ -58,12 +57,16 @@ void doHud(void) healthWarning++; healthWarning %= FPS; + numMessages = 0; + prev = &hudMessageHead; for (hudMessage = hudMessageHead.next ; hudMessage != NULL ; hudMessage = hudMessage->next) { hudMessage->life--; + numMessages++; + if (hudMessage->life <= 0) { if (hudMessage == hudMessageTail) @@ -74,6 +77,8 @@ void doHud(void) prev->next = hudMessage->next; free(hudMessage); hudMessage = prev; + + numMessages--; } prev = hudMessage; @@ -95,6 +100,17 @@ void addHudMessage(SDL_Color c, char *format, ...) hudMessage->color = c; hudMessage->life = FPS * 5; + + numMessages++; + + while (numMessages > MAX_HUD_MESSAGES) + { + hudMessage = hudMessageHead.next; + hudMessageHead.next = hudMessage->next; + free(hudMessage); + + numMessages--; + } } void drawHud(void) @@ -105,9 +121,7 @@ void drawHud(void) drawWeaponInfo(); - drawNumAllies(); - - drawNumEnemies(); + drawNumFighters(); drawObjectives(); @@ -231,22 +245,17 @@ static void drawPlayerTargeter(void) } } -static void drawNumAllies(void) +static void drawNumFighters(void) { + /* Allies */ SDL_SetTextureColorMod(smallFighter, 150, 200, 255); - blit(smallFighter, 400, 15, 0); + drawText(425, 11, 14, TA_LEFT, colors.white, "(%d)", battle.numAllies); - drawText(435, 11, 14, TA_CENTER, colors.white, "(%d)", battle.numAllies); -} - -static void drawNumEnemies(void) -{ + /* Enemies */ SDL_SetTextureColorMod(smallFighter, 255, 100, 100); - blit(smallFighter, SCREEN_WIDTH - 410, 15, 0); - - drawText(SCREEN_WIDTH - 430, 11, 14, TA_CENTER, colors.white, "(%d)", battle.numEnemies); + drawText(SCREEN_WIDTH - 420, 11, 14, TA_RIGHT, colors.white, "(%d)", battle.numEnemies); } static void drawObjectives(void) diff --git a/src/battle/hud.h b/src/battle/hud.h index 993f2e8..14b41a5 100644 --- a/src/battle/hud.h +++ b/src/battle/hud.h @@ -23,6 +23,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "../defs.h" #include "../structs.h" +#define MAX_HUD_MESSAGES 6 + extern SDL_Texture *getTexture(char *filename); extern void blitRotated(SDL_Texture *texture, int x, int y, int angle); extern void blit(SDL_Texture *texture, int x, int y, int center);