9.5.2

Table Of Contents
1068 CHAPTER 22
XPRESSO EDITOR 1069
If the wires in an expression are tangled, reposition the ports by Alt-dragging each port to a new
position. You can reposition vertically only. You cannot, for example, Alt-drag an input port from the
node’s left edge to the right edge.
Wires will convert compatible data types automatically. For example, if you pass a real value, such as
72.163, to a node that works with integers only, the connecting wire will convert the real value to an
integer automatically — in this case, to 72.
Creating a new XPresso expression
The rst step in building an expression is to add an XPresso tag to one of the objects in the scene
(Object manager: File > CINEMA 4D Tags > XPresso). Although this can be any object in the scene,
you’ll probably want to assign the tag to an object that is somehow involved in the expression. Once
you’ve assigned the tag, the XPresso Editor opens — this is where you build your expressions.
You can close the editor window at any time; to re-open it, double-click the XPresso tag in the Object
manager.
Setting the priority
Depending on the scene, the priority of expressions can be critical. For example, suppose your scene
has an expression that hovers a rain cloud over a character’s head for a number of frames while the
character (named Bob) is walking. In this case, it is essential that the expression is evaluated after
Bob’s animation, otherwise the rain cloud would be placed over Bob’s old position and would lag
one frame behind. By setting the priority of your expressions, you can ensure they are evaluated at
the right time.
XPriority
To set the expression’s priority, in the Object manager select its XPresso tag and, in the Attribute
manager, set XPriority to the desired priority.
The expression will be evaluated at the same time as the group that you choose from this drop-down
list (provided that the value in the adjacent input box is 0). The order of evaluation in the XPriority
drop-down list is from top to bottom. For example, if you set XPriority to Expressions, the expression
will be calculated at the same time as CINEMA 4D’s built-in expressions, i.e. after animation and before
dynamics. Returning to the rain cloud example, this would ensure that the rain cloud is positioned
after Bob’s animation rather than before, thus preventing the time-lag problem.