public static void Init() { string folderPath = AssetDatabase.GetAssetPath(Selection.activeObject); string copyPath = folderPath + "/New TileObject.cs"; NamingPopup.Create(folderPath); }
public static void Create(string path) { NamingPopup window = ScriptableObject.CreateInstance <NamingPopup>(); window.position = new Rect(Screen.width / 2, Screen.height / 2, 250, 150); window.ShowPopup(); window.folderPath = path; }