View Single Post
  #2  
Old 07-07-2016, 03:54 AM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Try using the viz.getFrameTime command. The frame time will not increase when viz.pause is called:

Code:
'''
Press 1 to play
Press 2 to pause
'''

import viz
import vizact
import vizinfo

viz.go()

vizinfo.InfoPanel()
viz.pause()

def printTime():
	print viz.getFrameTime()
	
vizact.ontimer(0,printTime)
vizact.onkeydown('1',viz.play)
vizact.onkeydown('2',viz.pause)
Reply With Quote