-
Notifications
You must be signed in to change notification settings - Fork 0
/
CurrentArea.h
42 lines (39 loc) · 1.32 KB
/
CurrentArea.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
#ifndef CURRENTAREA_H
#define CURRENTAREA_H
#include "Location.h"
#include "DisplayManager.h"
class CurrentArea
{
public:
/** Default constructor */
CurrentArea(LocalArea&, int x = 0, int y = 0, Rotation rot = DEGREE_0, bool mirrorx = false, bool mirrory = false);
CurrentArea(Location&, Rotation r = DEGREE_0, bool mirrorx = false, bool mirrory = false);
/** Default destructor */
virtual ~CurrentArea();
LocalArea getArea() {return *area;}
void setArea(LocalArea& local) {area = &local;}
int getX() {return x;}
void setX(int X) {x = X;}
int getY() {return y;}
void setY(int Y) {y = Y;}
int getDrawX();
int getDrawY();
Rotation getRotation() {return rot;}
void setRotation(Rotation rotation) {rot = rotation;}
void rotate(Rotation);
bool isMirroredX() {return mirroredX;}
void setMirroredX(bool mirror) {mirroredX = mirror;}
bool isMirroredY() {return mirroredY;}
void setMirroredY(bool mirror) {mirroredY = mirror;}
void mirrorX() {mirroredX += 1;}
void mirrorY() {mirroredY += 1;}
void print();
protected:
private:
LocalArea* area;
int x, y;
Rotation rot;
bool mirroredX;
bool mirroredY;
};
#endif // CURRENTAREA_H