public static bool IsPrefabDisconnected(this GameObject self) { #if UNITY_EDITOR return(self != null && PrefabUtility.GetPrefabType(self) == PrefabType.DisconnectedPrefabInstance); #else return(IsPrefab(self)); // fallback #endif }
public static bool IsPrefabOriginal(this GameObject self) { #if UNITY_EDITOR return(self != null && PrefabUtility.GetPrefabType(self) == PrefabType.Prefab); #else return(IsPrefab(self)); // fallback #endif }