Garry's Mod Wiki

DMenuOptionCVar

Description

This is used internally - although you're able to use it you probably shouldn't.

An internal panel used by DMenu. It acts as a menu option that can be checked. It automatically sets and reads the given console variable.

It can be right clicked to toggle without closing the DMenu.

Use DMenu:AddCVar instead.

Parent

Derives from DMenuOption.

Methods

string DMenuOptionCVar:GetConVar()
Returns the console variable used by the DMenuOptionCVar.
string DMenuOptionCVar:GetValueOff()
Returns the value of the console variable when the DMenuOptionCVar is not checked.
string DMenuOptionCVar:GetValueOn()
Return the value of the console variable when the DMenuOptionCVar is checked.
DMenuOptionCVar:SetConVar( string cvar )
Sets the console variable to be used by DMenuOptionCVar.
DMenuOptionCVar:SetValueOff( string value )
Sets the value of the console variable when the DMenuOptionCVar is not checked.
DMenuOptionCVar:SetValueOn( string value )
Sets the value of the console variable when the DMenuOptionCVar is checked.

Page Links


Special Pages


Wikis

?

Render Time: 68ms

DB GetPage 34
Generate Html 5
SaveChanges (1) 14
Render Body 0
Render Sidebar 12