-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstage.h
45 lines (32 loc) · 1.09 KB
/
stage.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
#ifndef EE319K_FINAL_PROJECT_INITIAL_TESTING_STAGES_H
#define EE319K_FINAL_PROJECT_INITIAL_TESTING_STAGES_H
#include <cstdint>
#include "entities.h"
class Stage {
#define CEIL_MAX 500
#define FLOOR_MAX -200
#define RIGHT_MAX 500
#define LEFT_MAX -200
#define SMASHVILLE_PLATFORM_ACCELERATON 0.07
#define SMASHVILLE_PLATFORM_MAXSPEED 2.0
#define SMASHVILLE_PLATFORM_DECELPOINTLEFT 50
#define SMASHVILLE_PLATFORM_DECELPOINTRIGHT 195
#define SMASHVILLE_PLATFORM_LENGTH 78
#define SMASHVILLE_PLATFORM_HEIGHT 5
protected:
double sv_platform_x, sv_platform_y, sv_platform_xvel;
bool sv_platform_goingRight;
public:
uint8_t stageIndex;
void initialize(uint8_t index, HitboxManager *hitboxManager);
void update();
double ceil(double x, double y);
double floor(double x, double y);
double rightBound(double x, double y);
double leftBound(double x, double y);
double getStartX(uint8_t player);
double getStartY(uint8_t player);
bool onPlatform(double x, double y);
double xVelocity(double x, double y);
};
#endif //EE319K_FINAL_PROJECT_INITIAL_TESTING_STAGES_H