|
|
|
Behavior EvaluateOnce one has attached code to objects using BehaviorEdit there are 2 effects one can use which will evaluate the code each frame. The behaviorSingle effect asks you, using the status bar, to pick the element whose code you wish to evaluate. behaviorEval looks at all the elements in the scene and finds those with attached code, so you don't have to select anything. Both behaviorEval and behaviorSingle skip disabled code, and both evaluate attached code according to the order set by BehaviorEdit. behaviorEval evaluates attached code evaluated EXACTLY once per frame. behaviorSingle will evaluate code each time Softimage updates the scene or whenever the object to which the code is attached is modified. Only behaviorEval generates FCurves. Both behaviorSingle and behaviorEval are "persistent" effects in Model->Effect. There are four procedures which help you to develop tcl scripts for element behavior. Note that these procedures are only useable within attached code (they use global variables defined within the behaviors code). You cannot use these procedures from the SoftWish Console:
Both behaviorEval and behaviorSingle determine which objects have attached code and read that code when you first invoke these effects. If you modify attached code after either behaviorEval or behavior Single is already active in a scene, or attach code to object(s) after behaviorEval is active, you must cause these effect to re-examine the scene using SWB_changeAttachedData (this especially useful if your behaviors are generating or modifying attached code). See AlsoExampleIf you attach the following tcl script to an element by using the Behavior Editor, then during execution by the Behavior Evaluator, the current frame number and the current element's name will be printed to the Softimage Command Prompt window.
|
|
copyright Video-Collage Inc. |