From 5bbc6351ceb0ccb69c9bbf780c39be063472b850 Mon Sep 17 00:00:00 2001 From: Roy Theunissen Date: Sun, 5 Oct 2025 16:55:52 +0200 Subject: [PATCH] Set up menu paths so they update if you rename the collection --- Scripts/Editor/EditorWindows/CreateCollectionWizard.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Scripts/Editor/EditorWindows/CreateCollectionWizard.cs b/Scripts/Editor/EditorWindows/CreateCollectionWizard.cs index 52c3963..3a140c1 100644 --- a/Scripts/Editor/EditorWindows/CreateCollectionWizard.cs +++ b/Scripts/Editor/EditorWindows/CreateCollectionWizard.cs @@ -639,7 +639,7 @@ private bool CreateCollectionScript() bool result = CodeGenerationUtility.CreateNewScript(CollectionName, folder, Namespace, - $"[CreateAssetMenu(menuName = \"ScriptableObject Collection/Collections/Create {CollectionName}\", fileName = \"{CollectionName}\", order = 0)]", + $"[CreateAssetMenu(menuName = \"ScriptableObject Collection/Collections/Create \" + nameof({CollectionName}), fileName = nameof({CollectionName}), order = 0)]", $"public class {CollectionName} : ScriptableObjectCollection<{collectionItemName}>", null, typeof(ScriptableObjectCollection).Namespace, "UnityEngine", "System.Collections.Generic");