public YellowCar() //Constructor { if( YellowCar = 1); setRotation(90); //set rotation to north if( else YellowCar = 2); setRotation(0); } }


public YellowCar() //Constructor { if( YellowCar = 1); setRotation(90); //set rotation to north if( else YellowCar = 2); setRotation(0); } }
public YellowCar(int direction) { if (direction == 0) setRotation(90); }
if( YellowCar = 1);
if( else YellowCar = 2);
else if (condition) { //statements; }
addObject(new YellowCar(0),30,15);