Browse Source

Merge pull request #719 from stevehalliwell/SpawnPrefab_assertion

Change FlowchartMenuItem.SpawnPrefab to GameObject.Inst rather than P…
master
Chris Gregan 6 years ago committed by GitHub
parent
commit
3798bbd209
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      Assets/Fungus/Scripts/Editor/FlowchartMenuItems.cs

4
Assets/Fungus/Scripts/Editor/FlowchartMenuItems.cs

@ -58,8 +58,8 @@ namespace Fungus.EditorUtils
return null; return null;
} }
GameObject go = PrefabUtility.InstantiatePrefab(prefab) as GameObject; GameObject go = GameObject.Instantiate(prefab) as GameObject;
PrefabUtility.DisconnectPrefabInstance(go); go.name = prefab.name;
SceneView view = SceneView.lastActiveSceneView; SceneView view = SceneView.lastActiveSceneView;
if (view != null) if (view != null)

Loading…
Cancel
Save