Package pygsear :: Module Path :: Class AccelerationPath
[show private | hide private]
[frames | no frames]

Class AccelerationPath

    Path --+    
           |    
VelocityPath --+
               |
              AccelerationPath


Move according to vel and accel in pixels per second.
Method Summary
  __init__(self, startLocation, vx, vy, ax, ay, gx, gy, duration)
  __iter__(self)
(inherited from Path)
  accelerate(self, ax, ay)
(inherited from VelocityPath)
  get_direction(self)
Return the direction from the previous location to the current location. (inherited from VelocityPath)
  get_position(self)
Return position along Path (inherited from Path)
  get_speed(self)
(inherited from VelocityPath)
  get_x(self)
return x component of position (inherited from Path)
  get_y(self)
return y component of position (inherited from Path)
  next(self, t)
Use velocity and acceleration info to move sprite, and return position.
  onscreen(self, slack)
true if path position is on main window (inherited from Path)
  pause(self)
stop moving along path (inherited from Path)
  reset(self)
put path back to original state
  set_acceleration(self, ax, ay)
  set_endTime(self, duration)
Path will raise StopIteration after self.duration seconds (inherited from Path)
  set_gravity(self, gx, gy)
  set_position(self, position)
Set position and update positionOld (inherited from Path)
  set_velocity(self, vx, vy)
(inherited from VelocityPath)
  unpause(self)
resume moving along path (inherited from Path)

Method Details

next(self, t=None)

Use velocity and acceleration info to move sprite, and return position.
Parameters:
t - Number of ticks since last update.
Returns:
position.

reset(self)

put path back to original state
Overrides:
pygsear.Path.Path.reset (inherited documentation)

Generated by Epydoc 1.1 on Sun Jan 25 19:10:10 2004 http://epydoc.sf.net