Examples:
|
The following creates a submenu named "Request Asset" and fills it with 3 options "SEAD", "CAS", and "CAP".
local requestM = missionCommands.addSubMenu('Request Asset')
local rSead = missionCommands.addCommand('SEAD', requestM, doRequestFunction, {type = 'SEAD"})
local rCAS = missionCommands.addCommand('CAS', requestM, doRequestFunction, {type = 'CAS"})
local rCAP= missionCommands.addCommand('CAP', requestM, doRequestFunction, {type = 'CAP"})
An example of how to create nested submenus...
local subR = missionCommands.addSubMenu('Root SubMenu')
local subN1 = missionCommands.addSubMenu('SubMenu within RootSubmenu', subR)
local subN2 = missionCommands.addSubMenu('we must go deeper', subN1)
local subN3 = missionCommands.addSubMenu('Go take a UX class', subN2)
|