CGame

Game functions

Type: Reference type

Methods

Declaration Description
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
bool AlertMessage(ALERT_TYPE aType, const string& in szFormat, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in, ?& in) Outputs a message to the console. Uses SC printf formatting style.
int PrecacheModel(const string& in szFileName) Precaches a model.
Shuts down the game if not found.
Can only be called from MapInit.
int PrecacheModel(CBaseEntity@ pEntity, const string& in szFileName) Precaches a model.
Shuts down the game if not found.
Can only be called from entity Precache methods.
void PrecacheOther(const string& in szClassName) Precaches an entity.
This effectively instances an entity with the given class name, calls precache on it, and removes the entity.
void PrecacheMonster(const string& in szClassName, bool fAlly) Precaches a monster entity.
This effectively instances a monster entity with the given class name, calls precache on it, and removes the entity.
void PrecacheGeneric(const string& in szFileName) Precaches a file for download to clients.
string GetGameName() const Returns the game name.
string GetGameVersionString() const Returns the game version as a string, e.g. "5.0".
uint32 GetGameVersion() const Returns the game version as a number, e.g. 500:
major version, minor version (3.0 becomes 300, 4.0b1 becomes 401, 4.06 becomes 406, 4.5 becomes 450, etc...)