summaryrefslogtreecommitdiff
path: root/src/editor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/editor.cpp')
-rw-r--r--src/editor.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/editor.cpp b/src/editor.cpp
index 74326bf..c97f375 100644
--- a/src/editor.cpp
+++ b/src/editor.cpp
@@ -19,7 +19,7 @@
#include "nfd.h"
#include "nfd.hpp"
#include "package.hpp"
-#include "tileset.hpp"
+#include "sets/tileset.hpp"
namespace silly::editor {
void Editor::update(const sf::Event &event, sf::RenderWindow &window) {
@@ -331,8 +331,8 @@ namespace silly::editor {
int columns = ImGui::GetContentRegionAvail().x / (imageSize + padding);
int count = 0;
- for (auto it = this->package.get_tileset().get_tiles().begin();
- it != this->package.get_tileset().get_tiles().end(); ++it) {
+ for (auto it = this->package.get_tileset().get_entries().begin();
+ it != this->package.get_tileset().get_entries().end(); ++it) {
if (ImGui::ImageButton(std::to_string(it->get()->id).c_str(),
it->get()->texture,
sf::Vector2f(imageSize, imageSize))) {
@@ -414,7 +414,7 @@ namespace silly::editor {
// -- Tile creation --
if (ImGui::Button("Create a new tile")) {
- this->package.get_tileset().add_tile(state.path, state.type);
+ this->package.get_tileset().add_entry(state.path, state.type);
ImGui::SetWindowCollapsed(true);
}