Your Ad Here

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

Synopsis

setDynamic( [obj[obj...]] , [allOnWhenRun=boolean], [disableAllOnWhenRun=boolean], [setAll=boolean], [setOff=boolean], [setOn=boolean])

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

setDynamic is undoable, queryable, and editable.

setDynamic sets the isDynamic attribute of particle objects on or off. If no objects are specified, it sets the attribute for any selected objects. If -all is thrown, it sets the attribute for all particle objects in the scene. By default it sets the attribute true (on); if the -off flag is thrown, it sets the attribute false (off). WARNING: setDynamic is obsolescent. This is the last version of Maya in which it will be supported.

Flags

allOnWhenRun, disableAllOnWhenRun, setAll, setOff, setOn
Long name (short name) [argument types] Properties
setAll(all) boolean
Set for all objects.
setOn(on) boolean
Sets isDynamic true. This flag is set by default.
setOff(off) boolean
Sets isDynamic false.
allOnWhenRun(awr) boolean
Obsolete, no longer suppported or necessary.
disableAllOnWhenRun(dwr) boolean
Obsolete, no longer suppported or necessary.

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.

Return value


string array

Python examples

import maya.cmds as cmds

cmds.setDynamic( 'myParticles', on=True )
# Sets myParticles.isDynamic true.

cmds.setDynamic( all=True, off=True )
# Sets isDynamic false for all particle objects in the scene.

  

Return to Autodesk Index


Your Ad Here