ConVar: Difference between revisions
Jump to navigation
Jump to search
m (otherlang2'd) |
No edit summary |
||
Line 15: | Line 15: | ||
</pre> | </pre> | ||
The default value given as the second argument of the ConVar constructor is '''not''' the value set. To set a value, use: | |||
<pre> | |||
pName->SetValue([value]); | |||
</pre> | |||
== Good practices == | == Good practices == | ||
Variables that you wish to be saved should be marked with flag [[FCVAR_ARCHIVE]]. Any cheat ConVar defined should not be archived. | Variables that you wish to be saved should be marked with flag [[FCVAR_ARCHIVE]]. Any cheat ConVar defined should not be archived. |
Revision as of 06:04, 4 August 2011
For a description of what a Console Variable is, see Commands and variables.
Documentation on specific console variables can be found at Category:Console Variables. For creating a new Console Variable see this. Developer Console Control
ConVar( const char *pName, const char *pDefaultValue, int flags, const char *pHelpString, bool bMin, float fMin, bool bMax, float fMax );
The default value given as the second argument of the ConVar constructor is not the value set. To set a value, use:
pName->SetValue([value]);
Good practices
Variables that you wish to be saved should be marked with flag FCVAR_ARCHIVE. Any cheat ConVar defined should not be archived.