Merge pull request #73714 from KoBeWi/tireset

Fix reset_state() in TileSet
This commit is contained in:
Rémi Verschelde 2023-02-22 10:13:01 +01:00
commit 44e9690108
No known key found for this signature in database
GPG key ID: C3336907360768E1
2 changed files with 5 additions and 1 deletions

View file

@ -2527,6 +2527,11 @@ void TileSet::reset_state() {
while (!source_ids.is_empty()) {
remove_source(source_ids[0]);
}
tile_shape = TILE_SHAPE_SQUARE;
tile_layout = TILE_LAYOUT_STACKED;
tile_offset_axis = TILE_OFFSET_AXIS_HORIZONTAL;
tile_size = Size2i(16, 16);
}
const Vector2i TileSetSource::INVALID_ATLAS_COORDS = Vector2i(-1, -1);

View file

@ -308,7 +308,6 @@ private:
TileLayout tile_layout = TILE_LAYOUT_STACKED;
TileOffsetAxis tile_offset_axis = TILE_OFFSET_AXIS_HORIZONTAL;
Size2i tile_size = Size2i(16, 16); //Size2(64, 64);
Vector2 tile_skew = Vector2(0, 0);
// Rendering.
bool uv_clipping = false;