-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRoom.h
More file actions
30 lines (26 loc) · 807 Bytes
/
Room.h
File metadata and controls
30 lines (26 loc) · 807 Bytes
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
#ifndef ROOM_H
#define ROOM_H
#include "Entity.h"
class Room {
string room_id;
int m_campfire;
Entity* roomEntity; //create Entity in the contractor method if there is a monster in the room
Room** roomsAccess; //dynamic array of Room pointers
int roomsCounter;
static int roomsCapacity;
public:
//constructors
Room(const string &roomID, int campfire, int monsterCurrAmountOfLife, int monsterAttackValue);
//copy constructor
Room(const Room& other);
//destructor
~Room();
Room& operator=(const Room* other);
Room* operator[](int index);
const Room* operator[](int index) const;
int getRoomCounter() const;
bool setRoomAccess(Room* room, int index);
string getID() const;
friend class Game;
};
#endif