WoW:API GetCVarDefault: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
No edit summary
 
(Filled out the GetCVarDefault stub.)
Line 1: Line 1:
{{wowapi}}
{{wowapi}} __NOTOC__
{{stub/api}}
 
GetCVarDefault allows you to get the default content of the variables defined in the config.wtf file (which is in the WTF directory).
 
value = GetCVarDefault("cvarName")
 
== Parameters ==
=== Arguments ===
:;cvarName: String - see [[Config.wtf defaults]] for a list
 
=== Returns ===
:;value: String
 
 
== Example ==
 
  DEFAULT_CHAT_FRAME:AddMessage(GetCVarDefault("screenshotFormat"))
 
Outputs "jpeg" in the chat frame.
 
== Notes ==
 
* Calling GetCVarDefault with an invalid variable name will cause an error


* See [[Config.wtf defaults]]
* See [[Config.wtf defaults]]

Revision as of 14:41, 8 June 2007

WoW API < GetCVarDefault

GetCVarDefault allows you to get the default content of the variables defined in the config.wtf file (which is in the WTF directory).

value = GetCVarDefault("cvarName")

Parameters

Arguments

cvarName
String - see Config.wtf defaults for a list

Returns

value
String


Example

 DEFAULT_CHAT_FRAME:AddMessage(GetCVarDefault("screenshotFormat"))

Outputs "jpeg" in the chat frame.

Notes

  • Calling GetCVarDefault with an invalid variable name will cause an error