$controller: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
m (cleanup) |
||
Line 2: | Line 2: | ||
<!-- confirm mouth = 1, confirm syntaxt of "tracker" --> | <!-- confirm mouth = 1, confirm syntaxt of "tracker" --> | ||
Allows the bone to be | Allows the bone to be controlled from game code. <!-- Although "mouth" can be used in place of a number it is the same as just using the number 1, this is hard-coded in studiocompiler. -->The axis can be X Y or Z. You can prefix L on the axis to specify this controller loops back around to the start when it ends, and/or suffix R to specify the start/end numbers are in {{wiki|radian}} units instead of degrees. | ||
The axis can be X Y or Z. You can prefix L on the axis to specify this controller loops back around to the start when it ends and/or | |||
If you need a controller over more then one axis you need to specify a new controller for each axis. | |||
$controller number "bone-name" axis start-offset end-offset | == Description == | ||
$controller number "bone-name" axis start-offset end-offset | |||
==Example== | == Example == | ||
$modelname "npcs/robot.mdl" | $modelname "npcs/robot.mdl" | ||
$cdmaterials "models/npcs/" | $cdmaterials "models/npcs/" | ||
$model "Robot" "robot.smd" | $model "Robot" "robot.smd" | ||
'''$controller 1 "jaw" X 0 20<!-- | '''$controller 1 "jaw" X 0 20<!-- $controller 2 "tracker" LYR -1 1 -->''' | ||
$sequence "idle" "idle.smd" | $sequence "idle" "idle.smd" |
Revision as of 09:42, 16 October 2007
Allows the bone to be controlled from game code. The axis can be X Y or Z. You can prefix L on the axis to specify this controller loops back around to the start when it ends, and/or suffix R to specify the start/end numbers are in radian units instead of degrees.
If you need a controller over more then one axis you need to specify a new controller for each axis.
Description
$controller number "bone-name" axis start-offset end-offset
Example
$modelname "npcs/robot.mdl" $cdmaterials "models/npcs/" $model "Robot" "robot.smd" $controller 1 "jaw" X 0 20 $sequence "idle" "idle.smd"