Go to: Synopsis. Return value. Keywords. Related. Flags. Python examples.

Synopsis

findType([deep=boolean], [exact=boolean], [type=string])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

findType is NOT undoable, NOT queryable, and NOT editable.

The findType command is used to search upstream through a dependency subgraph on a certain node to find all nodes of the given type. These will be nodes that affect the given one.

Return value

string[] The list of node(s) affecting the given node(s)

Keywords

debug, node, type, search

Related

affectedNet, affects, allNodeTypes, listConnections

Flags

deep, exact, type
Long name (short name) Argument types Properties
deep(d) boolean create
Find all nodes of the given type instead of just the first.
exact(e) boolean create
Match node types exactly instead of any in a node hierarchy.
type(t) string create
Type of node to look for (e.g. "transform"). This flag is mandatory.

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can have multiple arguments, passed either as a tuple or a list.

Python examples

import maya.cmds as cmds

cmds.createNode( 'transform', name='silly' )
cmds.createNode( 'transform', name='putty' )
cmds.connectAttr( 'silly.tx', 'putty.tx' )
# Find transform nodes connected to node "silly"
#
cmds.findType( type='transform', 'silly' )
# Result: silly #
cmds.select( 'silly' )
#
# Same again from selection list
#
cmds.findType( type='transform' )
# Result: silly #
cmds.setKeyframe( t=10 )
#
# Find all time nodes
#
cmds.findType( type='time', deep=True, e=True )
# Result: u'time1'   #
#
# Find all anim curve nodes
#
cmds.findType( type="animCurve", deep=True )
# Result: u'silly_visibility', u'silly_translateX', u'silly_translateY', u'silly_translateZ', u'silly_rotateX', u'silly_rotateY', u'silly_rotateZ', u'silly_scaleX', u'silly_scaleY', u'silly_scaleZ'   #