py city sun cycle
import maya.cmds
def create_animation(anim_range):
circle1 = cmds.circle(nr=(0,1,0),r=40)
for i in range(anim_range):
cmds.currentTime((i)*100, edit=True)
cmds.setKeyframe(circle1,v=(i*180), at=attribute)
cmds.keyTangent('nurbsCircle1', itt='linear', ott='linear')
cmds.playbackOptions( minTime='0', maxTime='99' )
anim_range=2
attribute="rotateX"
if cmds.window("new_window", exists=True):
cmds.deleteUI("new_window", window=True)
window = cmds.window( "new_window", title="NEW Window", iconName='Short Name', widthHeight=(300, 202), bgc=(1,0.1,0.3))
cmds.columnLayout( adjustableColumn=True )
cmds.button( label='Create Animation',c='create_animation(anim_range)', height=100)
cmds.button( label='Close', command=('cmds.deleteUI("new_window", window=True)'), height=100, bgc=(1,0,0))
cmds.setParent( '..' )
cmds.showWindow( window )
UP2115068 - TB2 SCRIPTS
TB2 SCRIPTS
More posts
- script_finalMay 20, 2023
- script 24/04/23Apr 24, 2023
- python city 20/03/23Mar 20, 2023
- random cubes arrange by widthJan 30, 2023
- city button testJan 23, 2023
Leave a comment
Log in with itch.io to leave a comment.