diff options
author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2015-03-10 19:42:04 -0400 |
---|---|---|
committer | Kelly Rauchenberger <fefferburbia@gmail.com> | 2015-03-10 19:42:04 -0400 |
commit | 0e0389752a0912614737e5c059b5cd4719ef9cf2 (patch) | |
tree | fc39e676bd819ee973f27fc40150a7874d2f8503 /src/map.h | |
parent | 7f0e8c7ef70c62814c274f110367db92f01cbb26 (diff) | |
download | therapy-0e0389752a0912614737e5c059b5cd4719ef9cf2.tar.gz therapy-0e0389752a0912614737e5c059b5cd4719ef9cf2.tar.bz2 therapy-0e0389752a0912614737e5c059b5cd4719ef9cf2.zip |
Const correctness!
Also created savefile and refactored collisions a bit.
Diffstat (limited to 'src/map.h')
-rw-r--r-- | src/map.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/map.h b/src/map.h index e3d1802..071b6f2 100644 --- a/src/map.h +++ b/src/map.h | |||
@@ -10,19 +10,19 @@ class Map { | |||
10 | Map& operator= (Map other); | 10 | Map& operator= (Map other); |
11 | friend void swap(Map& first, Map& second); | 11 | friend void swap(Map& first, Map& second); |
12 | 12 | ||
13 | const int* mapdata(); | 13 | const int* mapdata() const; |
14 | const char* title(); | 14 | const char* title() const; |
15 | Map* getLeftMap(); | 15 | const Map* getLeftMap() const; |
16 | Map* getRightMap(); | 16 | const Map* getRightMap() const; |
17 | void setLeftMap(Map* m); | 17 | void setLeftMap(const Map* m); |
18 | void setRightMap(Map* m); | 18 | void setRightMap(const Map* m); |
19 | private: | 19 | private: |
20 | Map(); | 20 | Map(); |
21 | 21 | ||
22 | int* m_mapdata; | 22 | int* m_mapdata; |
23 | char* m_title; | 23 | char* m_title; |
24 | Map* m_leftMap; | 24 | const Map* m_leftMap = nullptr; |
25 | Map* m_rightMap; | 25 | const Map* m_rightMap = nullptr; |
26 | }; | 26 | }; |
27 | 27 | ||
28 | #endif | 28 | #endif |