I've been told to make my class abstract:
public abstract class Airplane_Abstract
And to make a method called move virtual
public virtual void Move()
{
//use the property to ensure that there is a valid position object
double radians = PlanePosition.Direction * (Math.PI / 180.0);
// change the x location by the x vector of the speed
PlanePosition.X_Coordinate += (int)(PlanePosition.Speed * Math.Cos(radians));
// change the y location by the y vector of the speed
PlanePosition.Y_Coordinate += (int)(PlanePosition.Speed * Math.Sin(radians));
}
And that 4 other methods should be "pure virtual methods." What is that exactly?
They all look like this right now:
public virtual void TurnRight()
{
// turn right relative to the airplane
if (PlanePosition.Direction >= 0 && PlanePosition.Direction < Position.MAX_COMPASS_DIRECTION)
PlanePosition.Direction += 1;
else
PlanePosition.Direction = Position.MIN_COMPASS_DIRECTION; //due north
}