Grimm,
If you take a look at the API docs for the ScriptInterface class at the end you'll see a function called registerMenu()
https://lsd.ca/umc/docs/plugin-api/c...Interface.html
Example
Code:
public void init(ScriptInterface script) {
script.registerMenu(
"Salvage",
new JMenuItem("Materials"),
"com.lsd.udabot.plugins.salvage.Crafting",
"showFrame");
}
This registers the top level name Salvage under Plugins with a menu item of Materials which calls the showFrame() function of the com.lsd.udabot.plugins.salvage.Crafting class.