summaryrefslogtreecommitdiffstats
path: root/src/model/Map.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/model/Map.hpp')
-rw-r--r--src/model/Map.hpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/model/Map.hpp b/src/model/Map.hpp
index 6d3ef0e..e01d9c4 100644
--- a/src/model/Map.hpp
+++ b/src/model/Map.hpp
@@ -27,10 +27,14 @@
#pragma once
#include <cstdint>
+#include <deque>
#include <memory>
#include <stdexcept>
#include <vector>
+#include "Entity.hpp"
+
+
namespace RPGEdit {
namespace Model {
@@ -42,6 +46,9 @@ private:
size_t width, height;
std::unique_ptr<uint32_t[]> tiles;
+ mutable std::deque<std::shared_ptr<Entity>> entities;
+
+
Map(size_t width0, size_t height0)
: width(width0), height(height0), tiles(new uint32_t[width*height]) {
}
@@ -55,6 +62,10 @@ public:
return tileset;
}
+ std::deque<std::shared_ptr<Entity>> & getEntities() const {
+ return entities;
+ }
+
size_t getWidth() const {
return width;
}