com.ibm.rally
Interface IObject

All Known Subinterfaces:
ICar, ISpareTire

public interface IObject

This interface is implemented by all objects in the game. It allows you to get the location of any object, and to determine the distance and heading to or from the object.


Method Detail

getDistanceTo

public double getDistanceTo(double x,
                            double y)
Returns the distance to the given location.
Parameters:
double - x
double - y
Returns:
double

getDistanceTo

public double getDistanceTo(IObject obj)
Returns the distance to the given object.
Parameters:
IObject -  
Returns:
double

getHeadingTo

public int getHeadingTo(double x,
                        double y)
Returns the heading (angle) to the given location.
Parameters:
double - x
double - y
Returns:
int

getHeadingTo

public int getHeadingTo(IObject obj)
Returns the heading (angle) to the given object.
Parameters:
IObject -  
Returns:
int

getX

public double getX()
Return the X position.
Returns:
double

getY

public double getY()
Return the Y position.
Returns:
double