From 91ffa8637cddddae07c42115788e5104a5faca7f Mon Sep 17 00:00:00 2001 From: ilotterytea Date: Sat, 1 Feb 2025 23:19:16 +0500 Subject: feat: tile rotation --- src/floor.hpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/floor.hpp') diff --git a/src/floor.hpp b/src/floor.hpp index 1a6fe47..dcb9fa7 100644 --- a/src/floor.hpp +++ b/src/floor.hpp @@ -9,8 +9,9 @@ namespace silly::editor { struct Tile { - sf::Vector2i position; std::shared_ptr tile; + sf::Vector2i position; + float rotation; }; struct TileLayer { @@ -31,7 +32,7 @@ namespace silly::editor { void render(sf::RenderWindow &window) const; void place_tile(std::shared_ptr &tile, - const sf::Vector2i &position); + const sf::Vector2i &position, const float &rotation); void remove_tile(const sf::Vector2i &position); const int get_width() const; -- cgit v1.2.3