public List <CommandFormatDesc> GetCommands() { List <CommandFormatDesc> commands = new List <CommandFormatDesc>(); //selection commands commands.Add(new CommandFormatDesc("select.cameraSelect")); CommandArgDesc[] argDesc = { new CommandArgDesc("name", "string") }; commands.Add(new CommandFormatDesc("select.nameSelect", argDesc)); //UI commands commands.Add(new CommandFormatDesc("select.hide")); commands.Add(new CommandFormatDesc("select.show")); commands.Add(new CommandFormatDesc("select.clear")); //Component selection argDesc = new CommandArgDesc[1]; argDesc[0] = new CommandArgDesc("TypeName", "string"); commands.Add(new CommandFormatDesc("selection.selectComponent", argDesc)); argDesc = new CommandArgDesc[1]; argDesc[0] = new CommandArgDesc("showInspector?", "bool", true); commands.Add(new CommandFormatDesc("selection.detailed", argDesc)); commands.Add(new CommandFormatDesc("selection.gameObject")); return(commands); }
public List <CommandFormatDesc> GetCommands() { List <CommandFormatDesc> commands = new List <CommandFormatDesc>(); //verbose logging command CommandArgDesc[] argDesc = { new CommandArgDesc("useVerbose?", "bool", true) }; commands.Add(new CommandFormatDesc("console.verbose", argDesc)); //Log commands command argDesc = new CommandArgDesc[1]; argDesc[0] = new CommandArgDesc("logCommands?", "bool", true); commands.Add(new CommandFormatDesc("console.logCommands", argDesc)); //forwardToUnity command argDesc = new CommandArgDesc[1]; argDesc[0] = new CommandArgDesc("forwardMsgsToUnity?", "bool", true); commands.Add(new CommandFormatDesc("console.logToUnity", argDesc)); //List subscribers command commands.Add(new CommandFormatDesc("console.subscribers")); //clear console commands.Add(new CommandFormatDesc("console.clear")); argDesc = new CommandArgDesc[1]; argDesc[0] = new CommandArgDesc("filter", "string", true); commands.Add(new CommandFormatDesc("help", argDesc)); return(commands); }
public List <CommandFormatDesc> GetCommands() { List <CommandFormatDesc> commandList = new List <CommandFormatDesc>(macroListing.macros.Count); //build the list of commands foreach (Macro macro in macroListing.macros) { //build arg descriptors CommandArgDesc[] argDescs = new CommandArgDesc[macro.args.Count]; for (int i = 0; i < argDescs.Length; i++) { bool opt = (macro.args[i].defaultValue != null && macro.args[i].defaultValue.Length > 0); argDescs[i] = new CommandArgDesc(macro.args[i].name, macro.args[i].type, macro.args[i].desc, opt); } commandList.Add(new CommandFormatDesc(MACRO_PREFIX + macro.commandName, argDescs, macro.desc)); } return(commandList); }