WorldViz User Forum

WorldViz User Forum (
-   Vizard (
-   -   How to remove myTimerAction? (

Vishav 11-26-2018 08:14 PM

How to remove myTimerAction?
I am using this command in some function
myTimerAction = vizact.ontimer(8,dotappear)
and my function dotappear is:
def dotappear( ):
global point
point=viz.addText3D('o',pos=[1.24,0.78,0.4],scale =(0.01,0.01,0.01),color=(0,1,0))

and after 8 seconds dot appear on the screen.
After some if condition satisfies I want to remove/invisible point using:
But the point is not getting removed. Why?

Jeff 11-28-2018 08:30 PM

The function registered with vizact.ontimer will get called every 8 seconds. So you could be adding the point multiple times. In that case removing the point will only remove the last one added. If you want the callback function called only once, use the vizact.ontimer2 command instead.

Vishav 12-05-2018 04:49 AM

Thanks Jeff

All times are GMT -7. The time now is 02:40 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC