Thread: Tasks
View Single Post
  #3  
Old 01-07-2010, 09:59 AM
Moh200jo Moh200jo is offline
Member
 
Join Date: Feb 2009
Posts: 99
Thanks for this, and it is understood
I tried to do the following but still incorrect
Code:
def onCollideBegin(e):
	if e.obj1 == box1 and  e.obj2== box2:
                      print e.obj1 , “    ,” , e.obj2
                      action=vizact.call( task1())
viz.callback(viz.COLLIDE_BEGIN_EVENT,onCollideBegin)
ball=0
def task1():
global ball
	while ball <4:
		yield viztask.waitEvent(action)
		ball +=1
		
		print 'Number of Balls is : ',ball
My problem I do not understand how can connect these functions
Any help?
Reply With Quote