summaryrefslogtreecommitdiffhomepage
path: root/editor/scenery-editor.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-11-29 19:35:25 +0100
committerStanislaw Halik <sthalik@misaki.pl>2022-11-29 19:35:25 +0100
commitca6ff463979d5c250ab04e940bead875f11e7352 (patch)
tree479b06c90e1af3652c30e5554c3cada57ac81975 /editor/scenery-editor.hpp
parentcd1e7b6564e8508f84e84706557b89eb5471a978 (diff)
scenery wip
Diffstat (limited to 'editor/scenery-editor.hpp')
-rw-r--r--editor/scenery-editor.hpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/editor/scenery-editor.hpp b/editor/scenery-editor.hpp
index eb78bb01..8e47a6b8 100644
--- a/editor/scenery-editor.hpp
+++ b/editor/scenery-editor.hpp
@@ -1,5 +1,5 @@
#pragma once
-#include "src/scenery.hpp"
+#include "scenery.hpp"
#include <map>
#include <memory>
#include <Corrade/Containers/String.h>
@@ -7,12 +7,15 @@
namespace floormat {
struct anim_atlas;
+struct global_coords;
+struct world;
struct scenery_editor final
{
struct scenery_ final {
String name, descr;
scenery_proto proto;
+ operator bool() const noexcept;
};
scenery_editor() noexcept;
@@ -24,10 +27,11 @@ struct scenery_editor final
void select_tile(const scenery_& s);
void clear_selection();
- const scenery_& get_selected();
+ const scenery_& get_selected() const;
bool is_atlas_selected(const std::shared_ptr<anim_atlas>& atlas) const;
bool is_item_selected(const scenery_& s) const;
bool is_anything_selected() const;
+ void place_tile(world& w, global_coords pos, const scenery_& s);
auto cbegin() const noexcept { return _atlases.cbegin(); }
auto cend() const noexcept { return _atlases.cend(); }