$scale

From Valve Developer Community
Revision as of 14:15, 25 February 2018 by Ficool2 (talk | contribs) (Negative values are accepted, allows for flipping/mirroring animations)
Jump to navigation Jump to search

The $scale QC command multiplies the size of all subsequent SMDs. It does not affect values defined in the QC itself (e.g. $attachment locations).

Note.pngNote:$scale only affects SMDs that come after it in the QC. Specify it before any file references!
Note.pngNote:$scale also accepts negative values. This can be used to flip/mirror animations or models if the compiled model is then decompiled.
Warning.pngWarning:$scale prevents flex animation from working when using the VTA format. This limitation can be bypassed by using the DMX format.

Example

$modelname		"weapons/shell.mdl"
$cdmaterials	"models/weapons/"

$scale		3		// before any SMDs
$body		shell	"shell_ref.smd"
$sequence	idle	"shell_idle.smd"