-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsnake.h
42 lines (34 loc) · 897 Bytes
/
snake.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
struct snakeUnit{
point coords;
bool is = false; // you know, "it is" means it exists L0L, | I think therefore I am.
};
enum Direction{
None = 9,
Up = 1,
Right = 2,
Down = -1,
Left = -2
};
class Snake {
private:
Direction dir;
unsigned int len = 2;
unsigned int size = 0;
GLuint VBO = 0;
GLuint VAO = 0;
GLuint shader = 0;
public:
Snake(unsigned int size, GLuint shader = 0);
~Snake();
snakeUnit* snake;
void setDirection(Direction a);
void setLen(unsigned int len);
//void setVBO(GLuint vbo);
//void setVAO(GLuint vao);
//void setShader(GLuint shader);
Direction getDirection();
unsigned int getLen();
GLuint getVBO();
GLuint getVAO();
GLuint getShader();
};