Module state :: Class ShipExternalState
[hide private]
[frames] | no frames]

Class ShipExternalState

source code

The state of the ship for an outside observer

Instance Methods [hide private]
 
__init__(self, x, y, orientation, speed=0, angularSpeed=0)
Initialize an external state of a ship, namely its position and speeds
source code
 
__eq__(self, other) source code
 
__str__(self) source code
Method Details [hide private]

__init__(self, x, y, orientation, speed=0, angularSpeed=0)
(Constructor)

source code 

Initialize an external state of a ship, namely its position and speeds

Parameters:
  • x (float) - x-position, in meters
  • y (float) - y-position, in meters
  • orientation (float) - the ship orientation, where -180 < orientation <= 180 degrees
  • speed (float) - ship forward speed in m/sec (TODO: need to replace it by x-speed and y-speed)
  • angularSpeed (float) - ship angular speed in deg / sec