aboutsummaryrefslogtreecommitdiff
path: root/src/games/breakout/Breakout.hpp
blob: 9f2a0efd055ebb558dd98b739074a17676afee13 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#pragma once

#include <common/math.hpp>
#include <common/shapes.hpp>
#include <games/Game.hpp>


struct Ball {
    V3F32 pos;
    float radius;
};


class Breakout : public Game {
    enum GameStatus {
        resume,
        pause,
        exit
    };

public:
    Breakout() = default;
    bool Update(std::vector<SDL_Event> &events) override;

private:
    void ProcessEventDuringPause(SDL_Event& event);
    void ProcessEventDuringResume(SDL_Event& event);

    void Draw();
    void DrawPauseMenu();
    

private:
    GameStatus m_status;

    Circle m_circle;
};