public override void Action(int instanceId, string pathName, string resourceFile) { bool flag = false; if (this.sides < 0) { this.sides = 5; flag = true; } UnityEditor.Sprites.SpriteUtility.CreateSpritePolygonAssetAtPath(pathName, this.sides); if (flag) { Selection.activeObject = AssetDatabase.LoadMainAssetAtPath(pathName); SpriteEditorWindow.GetWindow(); } }
public override void Action(int instanceId, string pathName, string resourceFile) { bool showSpriteEditorAfter = false; if (sides < 0) { sides = 5; showSpriteEditorAfter = true; } Sprites.SpriteUtility.CreateSpritePolygonAssetAtPath(pathName, sides); if (showSpriteEditorAfter) { Selection.activeObject = AssetDatabase.LoadMainAssetAtPath(pathName); SpriteEditorWindow.GetWindow(); } }
internal static void ShowSpriteEditorWindow() { SpriteEditorWindow.GetWindow(); }