QuakeForge  0.7.2.210-815cf
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
cvar_s Struct Reference
Collaboration diagram for cvar_s:
[legend]

Data Fields

void(* callback )(struct cvar_s *var)
 Callback for when the cvar value changes. More...
 
const char * default_string
 The default value of the cvar. More...
 
const char * description
 for "help" command More...
 
int flags
 Cvar flags. More...
 
int int_val
 The current cvar value as an integer. More...
 
const char * name
 The name of the cvar. More...
 
struct cvar_snext
 
const char * string
 The current cvar value as a string. More...
 
float value
 The current cvar value as a float. More...
 
vec3_t vec
 The current cvar value as a vector. More...
 

Field Documentation

void(* callback)(struct cvar_s *var)

Callback for when the cvar value changes.

This allows for more flexibility in what happens when a cvar is nodifed than can be achieved with flags alone. While a similar could be done using commands, a cvar with a callback and CVAR_ARCHIVE set allows the setting to be saved automatically.

Parameters
varThis cvar.
const char* default_string

The default value of the cvar.

const char* description

for "help" command

int flags

Cvar flags.

int int_val

The current cvar value as an integer.

const char* name

The name of the cvar.

struct cvar_s* next
const char* string

The current cvar value as a string.

float value

The current cvar value as a float.

vec3_t vec

The current cvar value as a vector.


The documentation for this struct was generated from the following file: