refactor: header file for every module
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
#ifndef GAME_H
|
||||
#define GAME_H
|
||||
|
||||
#include <raylib.h>
|
||||
|
||||
#include "appCore.h"
|
||||
#include "birds.h"
|
||||
#include "clouds.h"
|
||||
#include "enemies.h"
|
||||
#include "engineInput.h"
|
||||
#include "enginePostfx.h"
|
||||
#include "engineSoundtrack.h"
|
||||
#include "engineSprite.h"
|
||||
#include "floor.h"
|
||||
#include "player.h"
|
||||
#include "projectiles.h"
|
||||
#include "terrain.h"
|
||||
#include "wake.h"
|
||||
#include "overlay.h"
|
||||
|
||||
typedef enum { POST_FX, SHADER_COUNT } ShaderID;
|
||||
typedef enum { GAMEPLAY_THEME, AMBIENT, SOUNDTRACK_COUNT } SoundtrackID;
|
||||
|
||||
typedef struct {
|
||||
Assets assets;
|
||||
PostProcessing postFX[SHADER_COUNT];
|
||||
Soundtrack soundtracks[SOUNDTRACK_COUNT];
|
||||
RenderTexture2D target;
|
||||
RenderTexture2D postFXTarget;
|
||||
Camera2D camera;
|
||||
Player player;
|
||||
Floor floor;
|
||||
Clouds clouds;
|
||||
Wake wake;
|
||||
Birds birds;
|
||||
Enemies enemies;
|
||||
Terrain terrain;
|
||||
Mouse mouse;
|
||||
Image image;
|
||||
Projectiles projectiles;
|
||||
Overlay overlay;
|
||||
} GameState;
|
||||
|
||||
void InitGame(App *app);
|
||||
void UpdateGame(App *app);
|
||||
void RenderComponents(App *app);
|
||||
void RenderGame(App *app);
|
||||
void ResetGame(App *app);
|
||||
void CleanupGame(App *app);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user