Skip to content

Commit ddfc69e

Browse files
authored
Merge pull request #75 from Unity-Technologies/UNI-22870-convert-to-model-saves-to-wrong-scene
UNI-22870 Convert to Model doesnt save to correct scene if muliple scenes open
2 parents 9821330 + 41971d9 commit ddfc69e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Assets/FbxExporters/Editor/ConvertToModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ public static GameObject[] CreateInstantiatedModelPrefab (GameObject [] unityGam
133133
Object unityMainAsset = AssetDatabase.LoadMainAssetAtPath("Assets/" + relativePath);
134134

135135
if (unityMainAsset != null) {
136-
Object unityObj = PrefabUtility.InstantiatePrefab (unityMainAsset);
136+
Object unityObj = PrefabUtility.InstantiatePrefab (unityMainAsset, gosToExport[i].scene);
137137
GameObject unityGO = unityObj as GameObject;
138138
if (unityGO != null)
139139
{

0 commit comments

Comments
 (0)