Commit a0796251 authored by Pierre MARQUE's avatar Pierre MARQUE

Fini mais pas de son

parent 64ca4b53
This diff is collapsed.
No preview for this file type
...@@ -6,15 +6,20 @@ ...@@ -6,15 +6,20 @@
typedef struct Paratrooper typedef struct Paratrooper
{ {
int life; int life;
float xDrop;
float yDrop;
bool droped; bool droped;
bool whichWay;
Rectangle hitbox; Rectangle hitbox;
Vector2 speed; Vector2 speed;
Color color; // yellow or red Color color; // yellow or red
Rectangle drag[10];
}Paratrooper; }Paratrooper;
typedef struct Aircraft typedef struct Aircraft
{ {
int life; int life;
float height;
float xFirstToJump; float xFirstToJump;
int numberOfParatroopers; int numberOfParatroopers;
Rectangle hitbox; Rectangle hitbox;
...@@ -61,12 +66,24 @@ typedef struct AntiParaCanon ...@@ -61,12 +66,24 @@ typedef struct AntiParaCanon
Vector2 aimingPosition; Vector2 aimingPosition;
}AntiParaCanon; }AntiParaCanon;
typedef struct Viewfinder
{
Rectangle up;
Rectangle down;
Rectangle left;
Rectangle right;
float radius;
Vector2 center;
Color color;
}Viewfinder;
//------------------------------------------------------------------------------------ //------------------------------------------------------------------------------------
// Module Functions Declaration // Module Functions Declaration
//------------------------------------------------------------------------------------ //------------------------------------------------------------------------------------
static void InitGame(void); // Initialize game static void InitGame(void); // Initialize game
static void UpdateGame(); // Update game (one frame) static void UpdateGame(void); // Update game (one frame)
static void DrawGame(void); // Draw game (one frame) static void DrawGame(void); // Draw game (one frame)
static void UnloadGame(void); // Unload game static void UnloadGame(void); // Unload game
...@@ -76,11 +93,19 @@ static void UnloadGame(void); // Unload game ...@@ -76,11 +93,19 @@ static void UnloadGame(void); // Unload game
//Initialization functions------------------------------------------------------------ //Initialization functions------------------------------------------------------------
Aircraft InitializeAircraft(void); Aircraft InitializeAircraft(void);
AntiAircraftCanon InitializeAntiAircraftCanon(void);
AntiParaCanon InitializeAntiParaCanon(void);
Bombshell InitializeBombshell(void); Bombshell InitializeBombshell(void);
Bullet InitializeBullet(void); Bullet InitializeBullet(void);
Paratrooper InitializeParatrooper(void); Paratrooper InitializeParatrooper(void);
Viewfinder InitializeViewfinder(float decalage);
//Game functions---------------------------------------------------------------------- //Game functions----------------------------------------------------------------------
bool IsRectangleOut(Rectangle rec); bool IsRectangleOut(Rectangle rec);
bool IsCircleOut(Vector2 center, float radius); bool IsCircleOut(Vector2 center, float radius);
Aircraft MoveAircrafts(Aircraft aircraft);
Bombshell MoveBombshell(Bombshell bombshell);
Bullet MoveBullet(Bullet bullet);
Paratrooper MoveParatrooper(Paratrooper paratrooper);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment