Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.IO;
- using UnityEditor;
- using UnityEngine;
- public class Test : MonoBehaviour
- {
- [ContextMenu("Run")]
- private void Run()
- {
- var scenePaths = Directory.GetFiles(Application.dataPath, "*.unity", SearchOption.AllDirectories);
- foreach(var path in scenePaths)
- {
- var unityPath = FileUtil.GetProjectRelativePath(path);
- var unityScene = AssetDatabase.LoadAssetAtPath<SceneAsset>(unityPath);
- Debug.Log(unityScene);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement