Quantcast
Channel: Questions in topic: "prefab connection"
Viewing all articles
Browse latest Browse all 103

PrefabUtility.ReplacePrefab overrides changes

$
0
0
Hi, I want to update a prefab programatically but somehow my changes get overwritten in the scene. When I delete a child transform in my prefabInstance in the scene and then try to update the prefab itself. The changes get reverted when I do this. GameObject rNewPrefab = PrefabUtility.ReplacePrefab(a_rPrefabInstance, pref, ReplacePrefabOptions.ReplaceNameBased); If I first create a empty prefab and overwrite the existing one the changes get applied but the prefabconnection gets broken. I've also tried ReplacePrefabOptions.ConnecToPrefab but that did not help either. Does anybodey know what might be causing this? Thx in advance!

Viewing all articles
Browse latest Browse all 103

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>