diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-12-10 10:45:52 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-10 10:45:52 +0100 |
commit | cc5d2c68a86bfa06ed28c92636c7bc44def9f5e3 (patch) | |
tree | d10c7ce658aa674bb136eb3783770615aff61886 | |
parent | daa504c6406222ab3a9c40b8cfdb1a5eb10ef087 (diff) | |
parent | 8a22d4cd442481853228a56e38487247821258b9 (diff) |
Merge pull request #69842 from timothyqiu/tile-set-update
Fix !tile_set.is_valid() error on startup
-rw-r--r-- | editor/plugins/tiles/tile_set_editor.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/editor/plugins/tiles/tile_set_editor.cpp b/editor/plugins/tiles/tile_set_editor.cpp index 934de05cfb..e8ceacf8f8 100644 --- a/editor/plugins/tiles/tile_set_editor.cpp +++ b/editor/plugins/tiles/tile_set_editor.cpp @@ -120,7 +120,9 @@ bool TileSetEditor::_can_drop_data_fw(const Point2 &p_point, const Variant &p_da } void TileSetEditor::_update_sources_list(int force_selected_id) { - ERR_FAIL_COND(!tile_set.is_valid()); + if (tile_set.is_null()) { + return; + } // Get the previously selected id. int old_selected = TileSet::INVALID_SOURCE; |