Exemplo n.º 1
0
 public static bool PreviewAssetStoreAssetBundleInInspector(AssetBundle bundle, AssetStoreAsset info)
 {
     info.id           = 0;
     info.previewAsset = bundle.mainAsset;
     AssetStoreAssetSelection.Clear();
     AssetStoreAssetSelection.AddAssetInternal(info);
     Selection.activeObject = AssetStoreAssetInspector.Instance;
     AssetStoreAssetInspector.Instance.Repaint();
     return(true);
 }
        public static bool PreviewAssetStoreAssetBundleInInspector(AssetBundle bundle, AssetStoreAsset info)
        {
            info.id           = 0; // make sure the id is zero when previewing
            info.previewAsset = bundle.mainAsset;
            AssetStoreAssetSelection.Clear();
            AssetStoreAssetSelection.AddAssetInternal(info);

            // Make the inspector show the asset
            Selection.activeObject = AssetStoreAssetInspector.Instance;
            AssetStoreAssetInspector.Instance.Repaint();
            return(true);
        }