summaryrefslogtreecommitdiffhomepage
path: root/editor
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-11-29 14:49:53 +0100
committerStanislaw Halik <sthalik@misaki.pl>2022-11-29 14:49:59 +0100
commitdd7774c77bba183615f1884514a4f3de4e23eb5a (patch)
treeaab90b3152eed45cd8d2aa0c4e97606c7c7c6bea /editor
parent1468845c9a7fe9629142227d1bef0302a39fce81 (diff)
anim, scenery: persist scenery rotation in editor
Diffstat (limited to 'editor')
-rw-r--r--editor/scenery-editor.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/editor/scenery-editor.cpp b/editor/scenery-editor.cpp
index dd7ca563..a6870180 100644
--- a/editor/scenery-editor.cpp
+++ b/editor/scenery-editor.cpp
@@ -41,7 +41,11 @@ void scenery_editor::prev_rotation()
void scenery_editor::select_tile(const scenery_& s)
{
+ const auto rot = is_anything_selected() && s.proto.atlas->check_rotation(_selected.proto.frame.r)
+ ? _selected.proto.frame.r
+ : s.proto.frame.r;
_selected = s;
+ _selected.proto.frame.r = rot;
}
void scenery_editor::clear_selection()