This article's documentation is for anything that uses the Source engine. Click here for more information.

$animblocksize: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Fix first line to improve legibility & improved several lines.)
mNo edit summary
Line 2: Line 2:
{{this is a|QC command|name=$animblocksize}} It changes how animation data is stored within the model.
{{this is a|QC command|name=$animblocksize}} It changes how animation data is stored within the model.


Normally, all animation data is stored in the <code>[[MDL|.mdl]]</code> file. If this is specified, all the animation data will instead be written to a <code>[[ANI|.ani]]</code> file, and when sequences are needed, the data will be loaded on demand. This is helpful for streaming animation data of [[Cinematic Physics]]. The "size in K" is the block size the animations will be grouped into. Sizes between 4K and 64K are fine, though 16K or 32K has better memory fragmentation characteristics.
Normally, all animation data is stored in the <code>[[MDL|.mdl]]</code> file. If this is specified, all the animation data will instead be written to a <code>[[ANI|.ani]]</code> file, and when sequences are needed, the data will be loaded on demand. This is helpful for streaming animation data of [[baked physics]]. The "size in K" is the block size the animations will be grouped into. Sizes between 4K and 64K are fine, though 16K or 32K has better memory fragmentation characteristics.


The <code>nostall</code> option will embed the first [[$sectionframes|block]] in the <code>.mdl</code> file. This usually prevents a model from stalling when loaded mid-game, if it has particularly complex animations that otherwise might take some time to load.
The <code>nostall</code> option will embed the first [[$sectionframes|block]] in the <code>.mdl</code> file. This usually prevents a model from stalling when loaded mid-game, if it has particularly complex animations that otherwise might take some time to load.

Revision as of 12:26, 16 August 2024

English (en)Translate (Translate)

$animblocksize is a QC command available in all Source Source games. It changes how animation data is stored within the model.

Normally, all animation data is stored in the .mdl file. If this is specified, all the animation data will instead be written to a .ani file, and when sequences are needed, the data will be loaded on demand. This is helpful for streaming animation data of baked physics. The "size in K" is the block size the animations will be grouped into. Sizes between 4K and 64K are fine, though 16K or 32K has better memory fragmentation characteristics.

The nostall option will embed the first block in the .mdl file. This usually prevents a model from stalling when loaded mid-game, if it has particularly complex animations that otherwise might take some time to load.

Icon-Bug.pngBug:In games with support for compressed (repacked) maps, the client will crash when attempting to load on-demand animation data if the content is packed into the BSP.  [todo tested in ?]

Syntax

$animblocksize	(size in K) ["nostall"]

Example

Found in Left 4 Dead 2, "general_dest_plaster_set.mdl":

$animblocksize	32 nostall highres

See also