Hosting and domain costs until October 2024 have been generously sponsored by dumptruck_ds. Thank you!

Difference between revisions of "precache model"

From Quake Wiki

Line 4: Line 4:
 
Precaches a model for use by the engine.  Any model that you want to use MUST be precached.  Precaching can only be done during map load, not afterwards.  Doing so will cause the engine to crash. Use [[precache_model2]] for registered Quake.
 
Precaches a model for use by the engine.  Any model that you want to use MUST be precached.  Precaching can only be done during map load, not afterwards.  Doing so will cause the engine to crash. Use [[precache_model2]] for registered Quake.
 
====Parameters:====
 
====Parameters:====
:<code>s</code> - The path to the model being precached
+
:<code>s</code> - The path to the model (mdl, bsp or spr) being precached
 
====Returns:====
 
====Returns:====
 
:Returns a string (what string?).  This is usually ignored.
 
:Returns a string (what string?).  This is usually ignored.

Revision as of 17:37, 2 May 2015

Syntax:

string precache_model(string s)

Precaches a model for use by the engine. Any model that you want to use MUST be precached. Precaching can only be done during map load, not afterwards. Doing so will cause the engine to crash. Use precache_model2 for registered Quake.

Parameters:

s - The path to the model (mdl, bsp or spr) being precached

Returns:

Returns a string (what string?). This is usually ignored.