diff options
author | Gilles Roudière <gilles.roudiere@gmail.com> | 2019-03-07 19:02:16 +0100 |
---|---|---|
committer | Gilles Roudière <gilles.roudiere@gmail.com> | 2019-03-07 21:05:23 +0100 |
commit | a6c229bbfd038ad7cf06460007608e3b5bc97025 (patch) | |
tree | 27fa87103a5b03e33623745c5119b7439c3921f2 /scene/2d/sprite.cpp | |
parent | 6cb841edcb1295a4877ed27330f0ba4c049ddafa (diff) |
Fixes bad gizmo alignment for textures with odd size
Diffstat (limited to 'scene/2d/sprite.cpp')
-rw-r--r-- | scene/2d/sprite.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/2d/sprite.cpp b/scene/2d/sprite.cpp index ba103a8bf0..a8c7622828 100644 --- a/scene/2d/sprite.cpp +++ b/scene/2d/sprite.cpp @@ -363,7 +363,7 @@ Rect2 Sprite::get_rect() const { Point2 ofs = offset; if (centered) - ofs -= s / 2; + ofs -= Size2(s) / 2; if (s == Size2(0, 0)) s = Size2(1, 1); |