-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgame.h
49 lines (39 loc) · 1.07 KB
/
game.h
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
39
40
41
42
43
44
45
46
47
48
#pragma once
#include <string>
#include "raylib.h"
#include "config.h"
// #include "bird.h"
// #include <vector>
#include "obstacle.h"
#include "items.h"
#include "buttonActionMap.h"
enum class Gamestate
{
pause, game
};
class Game
{
public :
void Init(int width, int height, std::string title);
~Game() noexcept;
void Tick();
private:
void Draw();
void Update();
void Reset();
void DrawBackground();
void ObstacleLogic();
Texture2D backgroundImage; // Texture loading;
// Music music; // 배경음악 선언
// 플레이어
Bird bird;
// 장애물 변수 선언
std::vector<Obstacle> pipes;
int timer = 0;
int maxTimer = 120;
Texture2D UpPipeImage; // Texture loading;
Texture2D DownPipeImage; // Texture loading;
// Items 에이전트
Items* items;
int gamepad = 0; // 제일 처음에 꽂은 게임패드만 사용하도록 하자. 제일 처음이므로 0이다.
};