浏览代码

Merge pull request #33964 from aaronfranke/canvas-in-spatial-crash

Don't cast item to Spatial when checking if it's locked
Rémi Verschelde 5 年之前
父节点
当前提交
7735af7e76
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      editor/plugins/spatial_editor_plugin.cpp

+ 1 - 1
editor/plugins/spatial_editor_plugin.cpp

@@ -521,7 +521,7 @@ void SpatialEditorViewport::_select_region() {
 
 		if (selected.find(item) != -1) continue;
 
-		if (_is_node_locked(Object::cast_to<Spatial>(item))) continue;
+		if (_is_node_locked(item)) continue;
 
 		Ref<EditorSpatialGizmo> seg = sp->get_gizmo();