View Single Post
Old 04-09-2013, 02:41 PM
Jeff Jeff is offline
WorldViz Team Member
Join Date: Aug 2008
Posts: 2,466
If you're waiting for either the walk action to finish or the keypress to occur you should use the viztask.waitAny command. Then if the event was a keypress you can leave the task using the return command:
d = yield viztask.waitAny([waitSpaceBar,waitAction])
condition = d.condition
if condition == waitSpaceBar:
Reply With Quote