Skip to content

Commit

Permalink
- feat: project path bug fix, window rename
Browse files Browse the repository at this point in the history
  • Loading branch information
re-mouse committed Nov 20, 2022
1 parent 282aee9 commit d59d424
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Editor/NodeViewerWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ namespace Irehon.Editor
{
public class NodeViewerWindow : EditorWindow
{
private static readonly string WindowName = "Assets dependencies";
private static readonly string WindowName = "Assets";
private NodeGUILayout nodeGUILayout;
private Vector2 scrollPosition;

Expand Down
11 changes: 5 additions & 6 deletions Editor/ProjectEditorUtilities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,13 @@ public static string[] GetAllAssetsPaths()

public static string[] GetDependenciesPath()
{
var gameScenes = AssetDatabase.FindAssets("t:Scene", new string[] { "Assets/Scenes" });

string[] scenesAssetId = new string[gameScenes.Length];
var scenes = EditorBuildSettings.scenes;
string[] gameScenesPath = new string[scenes.Length];

for (int i = 0; i < gameScenes.Length; i++)
scenesAssetId[i] = AssetDatabase.GUIDToAssetPath(gameScenes[i]);;
for (int i = 0; i < scenes.Length; i++)
gameScenesPath[i] = scenes[i].path;

return AssetDatabase.GetDependencies(scenesAssetId);
return AssetDatabase.GetDependencies(gameScenesPath);
}
}
}

0 comments on commit d59d424

Please sign in to comment.