Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cmds.file(q=1,exn=1)
- cmds.lis
- cmds.ls(type='reference')
- detection_dict = {}
- for ac in cmds.listConnections('Robot_Boomer_01RN.placeHolderList',type='animCurve'):
- detection_dict[ac]=detect_stray_changes(ac)
- [a for a in detection_dict if detection_dict[a]==True]
- def detect_stray_changes(ctrl):
- key_locs = []
- tmin = cmds.playbackOptions(q=1,min=1)
- cmds.currentTime(tmin,update=0)
- next_key = cmds.findKeyframe( ctrl ,timeSlider=True, which="next" )
- while next_key not in key_locs:
- key_locs.append(next_key)
- cmds.currentTime(next_key,update=0)
- next_key = cmds.findKeyframe( ctrl ,timeSlider=True, which="next" )
- no_change=False
- for key in key_locs:
- if 'scale' in ctrl:
- pass
- else:
- if cmds.getAttr(ctrl+'.output' )!=0:
- no_change=True
- return no_change
- aa = cmds.keyframe('COG_gimbal_Ctrl_rotateX',iv=1,q=1)
- cmds.keyframe('COG_gimbal_Ctrl_rotateX',index=tuple(aa))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement