-
Notifications
You must be signed in to change notification settings - Fork 0
/
constant.h
63 lines (48 loc) · 1013 Bytes
/
constant.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#ifndef CONSTANT_H
#define CONSTANT_H
#include <SDL.h>
const int SCREEN_WIDTH = 1280;
const int SCREEN_HEIGHT = 720;
const int MAX_NUMBER_IN_CELL = 8;
const char GAME_TITLE[] = "Minesweeper!";
const int TOP_LEFT_BOARD_X = 341;
const int TOP_LEFT_BOARD_Y = 61;
const int BOARD_WIDTH = 600;
const int BOARD_HEIGHT = 600;
//const int NUM_OF_BOMB = 80;
const int LONG_BUTTON_WIDTH = 200;
const int LONG_BUTTON_HEIGHT = 100;
const SDL_Color TEXT_COLOR = {255 ,255 ,255};
const int LEFT_BUTTON_POS_X = 440;
const int LEFT_BUTTON_POS_Y = 330;
const int RIGHT_BUTTON_POS_X = 790;
const int RIGHT_BUTTON_POS_Y = 330;
const int SQUARE_BUTTON_SIZE = 55;
enum GAME_STATE {
MAIN_MENU,
LEVEL_SELECT,
PLAYING,
PAUSING,
REVEAL_BOMB,
END_SCREEN,
};
enum CELL_STATE {
FLAG = -1,
NORMAL = 0,
SHOWN_CELL = 1,
};
enum BUTTON_STATE {
NO_MOUSE_OVER,
MOUSE_OVER,
};
enum DIFFICULTY {
EASY,
MEDIUM,
HARD,
};
enum MUSIC_PLAYING {
MENU,
WIN,
LOSE,
};
#endif