spawnmenu.AddToolMenuOption
spawnmenu.AddToolMenuOption( string tab, string category, string class, string name, string cmd = nil, string config = nil, function cpanel, table table = {} )
Description
Adds an option to the right side of the spawnmenu.
See spawnmenu.AddToolTab to add new right-side tabs. See spawnmenu.AddToolCategory to add new categories.
Arguments
3 string class
Unique internal identifier of the new option. This is used to reference this option by other code.
6 string config = nil
Config name, used in older versions to load tool settings UI from a file.
We advise against using this. It may be changed or removed in a future update.
Legacy argument, no longer works.
8 table table = {}
Allows to override the table that will be added to the tool list. Some of the fields will be overwritten by this function.
Example
Adds a new option to the menu with a slider to change the gravity
Output: 

Example
Example on how to add a custom tool tab with a custom tool category and a tool option.
Output: 

Garry's Mod
Rust
Steamworks
Wiki Help