vrdAimConstraintNode

class vrdAimConstraintNode

(Inherits vrdConstraintNode)

This class gives access to an aim constraint object in VRED. An aim constraint will compute the orientation of a constrained object depending on the position of a target and an optional up vector target. If there are multiple targets or up vector targets, the positions are calculated as the weighted average value of it.

For managing constraints and code examples see vrConstraintService.

Functions

vrdAimConstraintNode.clearUpVectorTargetNodes()

Clears the set up vector target nodes of the constraint.

vrdAimConstraintNode.getUpVectorTargetNodes()

Returns the list of nodes set as up vector targets for the constraint.

Returns:The list of constraint up vector target nodes.
Return type:List[vrdNode]
vrdAimConstraintNode.getUpVectorTargetNodeWeight(node)

Gets the weight for a up vector target node of the constraint. The node must be referenced in the up vector target nodes list of the constraint.

Parameters:node (vrdNode) – The up vector target node to get the weight for.
Returns:The weight for the up vector target node. If the node is not found, 0.0 is returned.
Return type:float
vrdAimConstraintNode.setUpVectorTargetNodes(nodes)

Sets a list of nodes as up vector targets for the constraint.

Parameters:nodes (List[vrdNode]) – The nodes to set as constraint up vector targets.
vrdAimConstraintNode.setUpVectorTargetNodeWeight(node, weight)

Sets the weight for an up vector target node of the constraint. The node must be referenced in the up vector target nodes list of the constraint.

Parameters:
  • node (vrdNode) – The up vector target node to set the weight for.
  • weight (float) – The weight for the up vector target node.