Newbie - Trouble using loops
Hi all,
I'm new to using Vizard and am having difficulty using loops. My issue is that when I use a loop, it blocks the environment from being rendered. I thought that this was OK as I was using the same method I saw in the Vizard documentation. Code:
import viz |
Functions scheduled with viztask must contain a yield command. The following should work:
Code:
import viz |
Thanks for the quick reply.
Yep, that worked. I must ask though, why is this? Using what you said, I have put the print statements in another function and I call that using a yield statement. |
Vizard's task functions are implemented using Python generators which use yield statements.
|
All times are GMT -7. The time now is 08:48 PM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC