$model (QC)
Jump to navigation
Jump to search
Specifies a reference SMD file to be used as part of a complex model. Simple models (including all $staticprops, should use $body.
Usage
$model <name> "<reference_model>.smd"
<name>- A unique identifier for this model.
<reference_model>- Path to a reference.smd, relative to $cd.
Simple example
$model "Shell" "shell.smd"
Options
eyeballname: Name of eyeball, used to match eyelid rules. For humans, userighteye: andlefteye:.bone_name: Name of bone that the eye is parented to, typically the head.X Y Z: World location of the center of the ball of the eye."material_name": Material name to use when searching for vertices to consider as the "white" of the eye used in dynamically texture mapping the iris and cornea onto the eye.diameter: Diameter of the ball of the eye.angle: Default yaw offset from "forward" for iris. Humans are typically 2-4 degrees wall-eyed. Not setting this correctly will result in either your characters appearing cross-eyed, or if you've compensated by misplacing the ball of the eye, them not tracking side to side. iris materialMaterial to use as the iris texture.pupil_scale: World scale of the iris texture.eyelidname: Base name of the eyelid flexcontroller. This is combined with the "lowerer", "neutral", and "raiser" options to build the piecewise blend positions of the eyelid.expression_file: The name of the file to find the morph targets.lowerer/neutral/raiser <frame> <height>: One of the three options, the frame number in theexpression_file, and the distance above or below the center of the pupil that polygon edge of the eyelid crosses the white of the eye.split <distance>: Where to start, on the opposite side of the "0" line, for finding vertices that belong to this eyelid morph target.eyeball <eyeball_name>: Name of the eyeball that will drive this eyelid's flexcontroller.- flex <name> <expression_file>
- Todo
- frame <frame> position split <distance>
- Todo
- defaultflex
- Todo
- flexfile <expression_file>
- Todo
- localvar <name> <name>
- Todo
- mouth <flexcontroller_name> <bone_name>
- Todo
- spherenormals <material_name> <X> <Y> <Z>
- Todo
Complex example
From sourcesdk_content\hl2\modelsrc\humans_sdk\Male_sdk\Male_06_sdk.qc:
$model male_06 "male_06_reference.smd"{
eyeball righteye "ValveBiped.Bip01_Head1" -1.2711 -4.2197 67.5593 "eyeball_r" 1 4 "pupil_r" 0.63
eyeball lefteye "ValveBiped.Bip01_Head1" 1.3572 -4.2197 67.5514 "eyeball_l" 1 -4 "pupil_l" 0.63
eyelid upper_right "male_06_expressions" lowerer 1 -0.2621 neutral 0 0.1287 raiser 2 0.2467 split 0.1 eyeball righteye
eyelid lower_right "male_06_expressions" lowerer 3 -0.3409 neutral 0 -0.2156 raiser 4 -0.0736 split 0.1 eyeball righteye
eyelid upper_left "male_06_expressions" lowerer 1 -0.2621 neutral 0 0.1287 raiser 2 0.2467 split -0.1 eyeball lefteye
eyelid lower_left "male_06_expressions" lowerer 3 -0.3409 neutral 0 -0.2156 raiser 4 -0.0736 split -0.1 eyeball lefteye
mouth 0 "mouth" "ValveBiped.Bip01_Head1" 0 1 0 // mouth illumination
flexfile "male_06_expressions" {
$include "../standardflex_xsi.qci"
}
$include "../facerules_xsi.qci"
$include "../bodyrules_xsi.qci"
}