Garry's Mod Wiki


  spawnmenu.AddToolTab( string name, string label = "name", string icon = "icon16/wrench.png" )


Adds a new tool tab to the right side of the spawnmenu via the SANDBOX:AddToolMenuTabs hook.

This function is a inferior duplicate of spawnmenu.GetToolMenu, just without its return value.


1 string name
The internal name of the tab. This is used for sorting.
2 string label = "name"
The 'nice' name of the tab (Tip: language.Add)
3 string icon = "icon16/wrench.png"
The filepath to the icon of the tab. Should be a .png


Creates a new tab named, "Tab name!" with a unique name and a wrench icon.

hook.Add( "AddToolMenuTabs", "myHookClass", function() spawnmenu.AddToolTab( "Tab name!", "#Unique_Name", "icon16/wrench.png" ) end )