cvars.public module

Provides a class that automatically sets the notify flag on load/unload.

class cvars.public.PublicConVar(name, value='0', description='', flags=0, min_value=None, max_value=None)[source]

Bases: _cvars.ConVar

Class used to set the notify flag on load/unload.

__init__(name, value='0', description='', flags=0, min_value=None, max_value=None)[source]

Set the cvar’s value and set the notify flag.

Parameters:
  • name (str) – Name of the console variable.
  • default (object) – A default value for the console variable. It will be converted to a string.
  • description (str/TranslationStrings) – A description of the console variable.
  • flags (ConVarFlags) – Flags that should be used for the console variable.
  • min_value (float) – Minimum value.
  • max_value (float) – Maximum value.