summaryrefslogtreecommitdiffhomepage
path: root/editor/wall-editor.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/wall-editor.hpp')
-rw-r--r--editor/wall-editor.hpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/editor/wall-editor.hpp b/editor/wall-editor.hpp
index b23cab60..bba395ad 100644
--- a/editor/wall-editor.hpp
+++ b/editor/wall-editor.hpp
@@ -2,6 +2,7 @@
#include "editor-enums.hpp"
#include "src/rotation.hpp"
#include "src/global-coords.hpp"
+#include "loader/wall-info.hpp"
#include <memory>
#include <map>
@@ -12,13 +13,18 @@ class wall_atlas;
class wall_editor
{
- std::map<StringView, std::shared_ptr<wall_atlas>> _atlases;
+ std::map<StringView, wall_info> _atlases;
std::shared_ptr<wall_atlas> _selected_atlas;
rotation _r = rotation::N;
void load_atlases();
public:
+ auto cbegin() const noexcept { return _atlases.cbegin(); }
+ auto cend() const noexcept { return _atlases.cend(); }
+ auto begin() const noexcept { return _atlases.cbegin(); }
+ auto end() const noexcept { return _atlases.cend(); }
+
wall_editor();
StringView name() const;
@@ -26,7 +32,7 @@ public:
void set_rotation(enum rotation r);
void toggle_rotation();
- const wall_atlas* get_selected() const;
+ std::shared_ptr<wall_atlas> get_selected() const;
void select_atlas(const std::shared_ptr<wall_atlas>& atlas);
void clear_selection();
bool is_atlas_selected(const std::shared_ptr<wall_atlas>& atlas) const;