-
Notifications
You must be signed in to change notification settings - Fork 0
/
zzxoto_constants.h
66 lines (54 loc) · 2.18 KB
/
zzxoto_constants.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
64
65
66
#ifndef ZZXOTO_CONSTANTS_H
#define ZZXOTO_CONSTANTS_H
//game width and height
const int GAME_WIDTH = 1280;
const int GAME_HEIGHT = 720;
const int COLOR_DARK = 0x0c0c0c;
const int COLOR_LIGHT = 0xf0f0f0;
//color
const int COLOR_BACKGROUND = COLOR_DARK;
const int COLOR_TEXT = COLOR_LIGHT;
const int COLOR_COLLISION_CIRCLE = 0xff0000;
const int COLOR_PLAYER = COLOR_LIGHT;
const int COLOR_BULLET = COLOR_LIGHT;
const int COLOR_ASTEROID = COLOR_LIGHT;
//player
const float PLAYER_SCALE = 25.f;
const float PLAYER_RESPAWN_SECONDS = 2.f;
const float PLAYER_MAX_VELOCITY = 150.f;
const int PLAYER_MAX_HEALTH = 3;
const int PLAYER_HEALTH_MODEL_SCALE = PLAYER_SCALE * .75f;
const float PLAYER_COLLISION_RADIUS = PLAYER_SCALE * .5f;
const float PLAYER_ANGULAR_VELOCITY_PS = 150.f;
//bullet
const float BULLET_VELOCITY = PLAYER_MAX_VELOCITY * 2.f;
const float BULLET_FIRE_FREQUENCY = 1.f / 4.f;
const float BULLET_LIFE_SECONDS_MAX = 2.f;
const float BULLET_COLLISION_RADIUS = 2.f;
const float BULLET_THICKNESS = 4.f;
//asteroid
const int ASTEROID_TYPE_LARGE = 1;
const int ASTEROID_TYPE_MEDIUM = 2;
const int ASTEROID_TYPE_SMALL = 3;
const int ASTEROID_SCORE_LARGE = 20;
const int ASTEROID_SCORE_MEDIUM = ASTEROID_SCORE_LARGE * 2;
const int ASTEROID_SCORE_SMALL = ASTEROID_SCORE_MEDIUM * 3;
const float ASTEROID_SCALE_SMALL = PLAYER_SCALE;
const float ASTEROID_SCALE_MEDIUM = PLAYER_SCALE * 2;
const float ASTEROID_SCALE_LARGE = PLAYER_SCALE * 6;
const float ASTEROID_COLLISION_RADIUS_SMALL = ASTEROID_SCALE_SMALL * .4;
const float ASTEROID_COLLISION_RADIUS_MEDIUM = ASTEROID_SCALE_MEDIUM * .4;
const float ASTEROID_COLLISION_RADIUS_LARGE = ASTEROID_SCALE_LARGE * .4;
const float ASTEROID_MIN_VELOCITY = PLAYER_MAX_VELOCITY / 4.f;
const float ASTEROID_MAX_VELOCITY = ASTEROID_MIN_VELOCITY * 2.f;
const float ASTEROID_MIN_ANGULAR_VELOCITY_PS = 0.f;
const float ASTEROID_MAX_ANGULAR_VELOCITY_PS = 60.f;
//welcome screen
const int WELCOMESCREEN_ASTEROID_LARGE_COUNT = 2;
const int WELCOMESCREEN_ASTEROID_MEDIUM_COUNT = 4;
const int WELCOMESCREEN_ASTEROID_SMALL_COUNT = 8;
//play screen
const int PLAYSCREEN_ASTEROID_LARGE_COUNT = 3;
const int PLAYSCREEN_ASTEROID_MEDIUM_COUNT = 2;
const int PLAYSCREEN_ASTEROID_SMALL_COUNT = 0;
#endif