-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathlocals.py
More file actions
48 lines (38 loc) · 868 Bytes
/
locals.py
File metadata and controls
48 lines (38 loc) · 868 Bytes
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
from enum import Enum
# 窗口网格的个数
HGRIDCOUNT = 32
VGRIDCOUNT = 24
# 网格大小
CEILSIZE = 20
# 窗口的宽度和高度
WINDOW_WIDTH = 1280
WINDOW_HEIGHT = 720
# 定义常用颜色
WHITE = (255, 255, 255)
BLACK = (0, 0, 0)
RED = (255, 0, 0)
GREEN = (0, 255, 0)
DARKGREEN = (0, 155, 0)
DARKGRAY = (40, 40, 40)
ORANGE = 255,156,0
YELLOW = 255,255,0
GREENBLUE = 0,255,255
BLUE = 0,0,255
PURPLE = 255,0,255
BGCOLOR = BLACK
# 页面类型
class PAGETYPE(Enum):
SPLASH = 0
GAME = 1
GAMEOVER = 2
# 游戏模式
class MODE(Enum):
SINGLE = 0
DOUBLE = 1
#------------------------- 图像识别 -------------------------#
# tensorflow人脸识别文件
PATH_TO_CKPT = './model/frozen_inference_graph_face.pb'
#------------------------- 小球运动的方向 -------------------------#
class Direction(Enum):
LEFT = 0
RIGHT = 1