/// <summary> /// Gets a scene reference for the specified asset path; /// </summary> /// <param name="assetPath"> /// The asset path of the scene. /// </param> public static SceneReference GetSceneReference(string assetPath) { return( Mode == SceneMapMode.Editor ? SceneMapEditorAdaptor.GetSceneReference(assetPath) : SceneMapPlayerAdaptor.GetSceneReference(assetPath) ); }
/// <summary> /// Gets the asset bundle name for the specified scene. /// </summary> /// <param name="guid"> /// The guid of the scene. /// </param> /// <returns> /// <c>null</c> if the scene is not in an asset bundle. /// </returns> public static string GetAssetBundleName(string guid) { return( Mode == SceneMapMode.Editor ? SceneMapEditorAdaptor.GetAssetBundleName(guid) : SceneMapPlayerAdaptor.GetAssetBundleName(guid) ); }
/// <summary> /// Gets the scene path for the specified scene. /// </summary> /// <param name="guid"> /// The guid of the scene. /// </param> /// <remarks> /// The scene path is different depending on where the scene is being loaded /// from. When the scene is being loaded from an asset bundle <see cref="SceneManager.LoadScene" /> /// only works if you pass the name of the scene. When the scene is being loaded /// normally, <see cref="SceneManager.LoadScene" /> works if you pass the name /// or path of the scene (as of Unity 5.3.4f1). /// </remarks> public static string GetScenePath(string guid) { return( Mode == SceneMapMode.Editor ? SceneMapEditorAdaptor.GetScenePath(guid) : SceneMapPlayerAdaptor.GetScenePath(guid) ); }
/// <summary> /// Gets a flag that indicates whether the scene map contains information about the specified scene. /// </summary> /// <param name="guid"> /// The guid of the scene. /// </param> public static bool Contains(string guid) { return( Mode == SceneMapMode.Editor ? SceneMapEditorAdaptor.Contains(guid) : SceneMapPlayerAdaptor.Contains(guid) ); }