summaryrefslogtreecommitdiffstats
path: root/editor/plugins/tiles/tile_atlas_view.cpp
diff options
context:
space:
mode:
authorbruvzg <7645683+bruvzg@users.noreply.github.com>2022-04-07 13:23:40 +0300
committerbruvzg <7645683+bruvzg@users.noreply.github.com>2022-04-20 10:34:00 +0300
commitde4c97758af117af97fad58e4a80ffeba0154ba8 (patch)
tree2139631cc24a59900a840b9371d5043183558fbd /editor/plugins/tiles/tile_atlas_view.cpp
parentf4b0c7a1ea8d86c1dfd96478ca12ad1360903d9d (diff)
downloadredot-engine-de4c97758af117af97fad58e4a80ffeba0154ba8.tar.gz
Fix more issues found by cppcheck.
Diffstat (limited to 'editor/plugins/tiles/tile_atlas_view.cpp')
-rw-r--r--editor/plugins/tiles/tile_atlas_view.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/plugins/tiles/tile_atlas_view.cpp b/editor/plugins/tiles/tile_atlas_view.cpp
index 71947ae185..4de2f42fe0 100644
--- a/editor/plugins/tiles/tile_atlas_view.cpp
+++ b/editor/plugins/tiles/tile_atlas_view.cpp
@@ -350,7 +350,7 @@ void TileAtlasView::_draw_alternatives() {
bool transposed = tile_data->get_transpose();
// Update the y to max value.
- Vector2i offset_pos = current_pos;
+ Vector2i offset_pos;
if (transposed) {
offset_pos = (current_pos + Vector2(texture_region_size.y, texture_region_size.x) / 2 + tile_set_atlas_source->get_tile_effective_texture_offset(atlas_coords, alternative_id));
y_increment = MAX(y_increment, texture_region_size.x);