示例#1
0
 def swallow(self, body):
   #print 'Reactor swallowing a body:', body.__class__
   if body.__class__ is Rotor: # TODO ugly hack
     print "create_rotor"
     self.rotor = self.create_rotor(0, 0, 5, 150)
   else:
     Plato.swallow(self, body)
示例#2
0
文件: newton.py 项目: antoinevg/phail
 def swallow(self, body):
   print 'swallowing a body:', body.__class__
   body.set_newton(self)
   Plato.swallow(self, body)