加餐啦~ public static class XXXEditorExtension{//Inspector 路径const string Path_0 = "CONTEXT/类名/xxx";//Hierachy 右键菜单路径const string Path_1 = "GameObject/xxx";//顶部菜单栏路径const string Path_2 = "CustomFunc/xxx";[MenuItem(Path_0)][MenuItem(Path_1)][MenuItem(Path_2)]public static void MenuItem_1(MenuCommand menucommand){var context = menucommand.context as 类名;}[MenuItem(itemName: Path_0, validate = true)][MenuItem(itemName: Path_1, validate = true)][MenuItem(itemName: Path_2, validate = true)]public static bool MenuItem_1_Validation(MenuCommand menucommand){var cs = menucommand.context as 类名;return 可以启用该功能?;} }