A new version of Cineversity has been launched. This legacy site and its tutorials will remain accessible for a limited transition period

Visit the New Cineversity


 ·   Wiki Home
 ·   Categories
 ·   Title List
 ·   Uncategorized Pages
 ·   Random Page
 ·   Recent Changes
 ·   RSS
 ·   Atom
 ·   What Links Here



Create or Find Page:


View Python: Setting Priorities


The following function can be used to set Priorities for objects that can have specific priorities(things like IK tags, constraints, morphs, etc. etc.).

def SetPriority(Mode, Value, obj):

    pd.SetPriorityValue(c4d.PRIORITYVALUE_MODE, Mode)
    pd.SetPriorityValue(c4d.PRIORITYVALUE_PRIORITY, Value)


Mode: Relates to the Drop down for the Priority. Should be populated with an int between 0-4.

0: Initial
1: Animation
2: Expression
3: Dynamics(R11.5)
4: Generators.

Anything over 4 will result in a Blank drop down.

Value: This is the number value you want to set your priority to. You have a range of 0-499.

obj: This is the object/tag that you want to set the Priority Data to.

Here’s an example of how to use it. First create a cube, then add a constraint tag onto it. With the Cube selected try the following code in your main function:

def main():
    SetPriority(4,100, tag)