def __init__(self, position0, world):
     self.INITIAL_SPEED = self.START_SPEED * (60.0 / world.FPS)
     self.TOO_SLOW = self.INITIAL_SPEED / 20.0
     self.SLOW_DOWN_BY = 0.2
     self.SLOWDOWN = self.SLOW_DOWN_BY * (60.0 / world.FPS)  #weird issues
     velocity0 = Vector2D.random() * self.INITIAL_SPEED
     MovingBody.__init__(self, position0, velocity0, world)
 def choose_velocity(self):
     return Vector2D.random() * random.uniform(
         self.MIN_SPEED, self.MAX_SPEED) * (60.0 / self.world.FPS)
Beispiel #3
0
 def __init__(self, position0, world):
     velocity0 = Vector2D.random() * self.INITIAL_SPEED
     MovingBody.__init__(self, position0, velocity0, world)