summaryrefslogtreecommitdiffhomepage
path: root/editor/scenery-editor.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2023-03-19 16:48:20 +0100
committerStanislaw Halik <sthalik@misaki.pl>2023-03-19 16:48:27 +0100
commit01bad2db72d987890590607fb0a6042ea7c21c3a (patch)
tree502e7c3e6bdec28e805c06bc50f16ba226b42e66 /editor/scenery-editor.cpp
parent86bd6a4411badecfc76fe3a9d29b4aa30c8fdba7 (diff)
fix scenery's json offset and rotation
Diffstat (limited to 'editor/scenery-editor.cpp')
-rw-r--r--editor/scenery-editor.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/editor/scenery-editor.cpp b/editor/scenery-editor.cpp
index fd859db3..6cfe56bf 100644
--- a/editor/scenery-editor.cpp
+++ b/editor/scenery-editor.cpp
@@ -22,6 +22,7 @@ scenery_editor::scenery_editor() noexcept
void scenery_editor::set_rotation(enum rotation r)
{
auto& s = _selected.proto;
+ s.offset = rotate_point(s.offset, s.r, r);
s.bbox_offset = rotate_point(s.bbox_offset, s.r, r);
s.bbox_size = rotate_size(s.bbox_size, s.r, r);
s.r = r;