engineer-thesis-WUT/breakout/game.hpp

35 lines
707 B
C++
Raw Normal View History

// Copyright [2023] Krzysztof Rudnicki
2023-04-02 17:59:15 +02:00
#ifndef BREAKOUT_GAME_HPP_
#define BREAKOUT_GAME_HPP_
#include <GLFW/glfw3.h>
#include "../dependencies/include/glad/glad.h"
2023-04-02 17:59:15 +02:00
// Represents the current state of the game
enum GameState {
GAME_ACTIVE,
GAME_MENU,
GAME_WIN
};
2023-04-02 17:59:15 +02:00
class Game
{
public:
// game state
GameState State;
bool Keys[1024];
unsigned int Width, Height;
// constructor/destructor
Game(unsigned int width, unsigned int height);
~Game();
// initialize game state (load all shaders/textures/levels)
void Init();
// game loop
void ProcessInput(float dt);
void Update(float dt);
void Render();
2023-04-02 17:59:15 +02:00
};
#endif // BREAKOUT_GAME_HPP_