-
Notifications
You must be signed in to change notification settings - Fork 0
/
StudentWorld.h
56 lines (50 loc) · 1.39 KB
/
StudentWorld.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
#ifndef STUDENTWORLD_H_
#define STUDENTWORLD_H_
#include "GameWorld.h"
#include "Level.h"
#include <string>
#include <vector>
// Students: Add code to this file, StudentWorld.cpp, Actor.h, and Actor.cpp
class Actor;
class Peach;
class StudentWorld : public GameWorld
{
public:
StudentWorld(std::string assetPath);
virtual ~StudentWorld();
int init();
int move();
void cleanUp();
bool bonk(double x, double y);
bool damage(double x, double y);
bool isBlockingObjectAt(double x, double y);
void newFireball(double x, double y, int dir, int type);
void newGoodie(double x, double y, int type);
void newShell(double x, double y, int dir);
void deleteActor();
bool isOverlapHelper(double x, double y);
bool isOverlap(double x, double y);
bool isOverlapPeachHelper(double x, double y);
bool isOverlapPeach(double x, double y);
void moveToNext();
void reachedMario();
bool getPeachPower(int type);
void gainPeachPower(int type, int num = 0);
void bonkPeach();
void damagePeach();
double getPeachX();
double getPeachY();
private:
std::vector<Actor*> m_actors;
Peach* m_peach;
std::string intToString(int input);
bool m_nexLevel;
bool m_reachedMario;
/*
starGoodie = 1 --> starPower
flowerGoodie = 2 --> shootPower
mushroomGoodie = 3 --> jumpPower
hit point = 4 --> hit point
*/
};
#endif // STUDENTWORLD_H_