Please be aware that when your script is using any of the UnityEditor classes, it should be excluded from the target build. For Unity 5.1.2, the priority of 21 is the maximum allowed priority for an item to exist still in the first group.įor more examples, please see the MainMenu documentation. Please note that in line 1 we need to set priority to make our menu entry to be placed in the first GameObject menu group, or it won’t be displayed in the Create menu. For instance, if you would like to place a custom entry under the Project’s Create button, you can write your code like this: Īlso you can add a menu entry to the Hierarchy’s Create menu: The main menu is not the only place when you can put your items. Looks like it works as expected! Not only in the main menu First thing that you will notice when this script is added to your project, is that you will find new menu entry.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |