Hosting and domain costs until October 2024 have been generously sponsored by dumptruck_ds. Thank you!
Difference between revisions of "cvar set"
From Quake Wiki
(Created page with "''void'' '''cvar_set'''(''string'' name, ''string'' val) == Usage == Sets the value of a console variable. All variables are stored as strings internally so this can be used...") |
(No difference)
|
Latest revision as of 17:42, 1 August 2023
void cvar_set(string name, string val)
Usage[edit]
Sets the value of a console variable. All variables are stored as strings internally so this can be used to change any variable.
Parameters[edit]
- name
- The name of the console variable.
- val
- The value to set it to.
Example[edit]
// Change the map's gravity based off which one it is if (self.model == "maps/e1m8.bsp") cvar_set("sv_gravity", "100"); else cvar_set("sv_gravity", "800");