diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2014-09-22 21:54:01 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2014-09-22 21:54:01 +0200 |
commit | fe0c3b733abf6eac5f4b5bc18f24f8a5cda1bfc4 (patch) | |
tree | 6f96e327b37fad557bd7cba7b45911c401f98ad2 /src/model/Map.hpp | |
parent | 6e67a0f13263b748718c692b4c6481a70b127fda (diff) | |
download | rpgedit-fe0c3b733abf6eac5f4b5bc18f24f8a5cda1bfc4.tar rpgedit-fe0c3b733abf6eac5f4b5bc18f24f8a5cda1bfc4.zip |
Render entities
Diffstat (limited to 'src/model/Map.hpp')
-rw-r--r-- | src/model/Map.hpp | 11 |
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; } |