View Single Post
  #4  
Old 05-02-2018, 03:56 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,462
The example code below alternates between running and idle animations:

Code:
import viz
import viztask

viz.go()
viz.addChild('piazza.osgb')
female = viz.add('vcc_female.cfg',pos=[0,0,5],euler=[90,0,0])

def ani_change():
	
	for i in range(5):
		female.state(11)
		yield viztask.waitTime(3)
		female.state(1)
		yield viztask.waitTime(1)

viztask.schedule(ani_change())
Reply With Quote