Buggy code:
public class DriveTrain { private IMotor leftBack ; private IMotor rightBack ; private IMotor leftFront ; private IMotor rightFront ; public boolean slowMode = false ; public DriveTrain ( IMotor leftFront , IMotor rightFront , IMotor leftBack , IMotor rightBack , boolean slowMode ) { } public void setMotorPower ( double leftBack , double rightBack , double leftFront , double rightFront ) { } public void setMotorPower ( double left , double right ) { } public void arcadeDrive ( GenericHID stick , boolean squaredInputs ) { } public void arcadeDrive ( GenericHID stick ) { } public void arcadeDrive ( GenericHID moveStick , final int moveAxis , GenericHID rotateStick , final int rotateAxis , boolean squaredInputs ) { } public void arcadeDrive ( GenericHID moveStick , final int moveAxis , GenericHID rotateStick , final int rotateAxis ) { } public void arcadeDrive ( double moveValue , double rotateValue ) { } public void arcadeDrive ( double moveValue , double rotateValue , boolean squaredInputs ) { } public void mecanumDrive_Cartesian ( double x , double y , double rotation , double gyroAngle ) { } private double trackingAngle ; private byte trackingStraight = 0 ; private double trackingTime = 0 ; public void resetGyro ( ) { } public void mecanumDrive_Cartesian2 ( double x , double y , double rotation , double gyroAngle ) { double xIn = x ; double yIn = y ; yIn = - yIn ; if ( ( Math . abs ( rotation ) ) < 0.075 ) { rotation = 0 ; if ( ( trackingStraight ) == 2 ) { if ( ( gyroAngle - ( trackingAngle ) ) >= 5 ) { rotation = - 0.15 ; } else if ( ( gyroAngle - ( trackingAngle ) ) <= ( - 5 ) ) { rotation = 0.15 ; } } else if ( ( trackingStraight ) == 1 ) { if ( ( trackingTime ) < ( System . currentTimeMillis ( ) ) ) { trackingStraight = 2 ; trackingAngle = gyroAngle ; } } else if ( ( trackingStraight ) == 0 ) { <START_BUG> trackintStraight = 1 ; <END_BUG> trackingTime = ( System . currentTimeMillis ( ) ) + 250 ; } } else { trackingStraight = 0 ; } double [ ] rotated = DriveTrain . rotateVector ( xIn , yIn , gyroAngle ) ; xIn = rotated [ 0 ] ; yIn = rotated [ 1 ] ; DriveTrain . SpeedStorage wheelSpeeds = new DriveTrain . SpeedStorage ( ) ; wheelSpeeds . FRONT_LEFT = ( xIn + yIn ) + rotation ; wheelSpeeds . FRONT_RIGHT = ( ( - xIn ) + yIn ) - rotation ; wheelSpeeds . BACK_LEFT = ( ( - xIn ) + yIn ) + rotation ; wheelSpeeds . BACK_RIGHT = ( xIn + yIn ) - rotation ; wheelSpeeds = new DriveTrain . SpeedStorage ( DriveTrain . normalize ( wheelSpeeds . getArray ( ) ) ) ; this . leftFront . setPower ( wheelSpeeds . FRONT_LEFT ) ; this . rightFront . setPower ( wheelSpeeds . FRONT_RIGHT ) ; this . leftBack . setPower ( wheelSpeeds . BACK_LEFT ) ; this . rightBack . setPower ( wheelSpeeds . BACK_RIGHT ) ; } public void mecanumDrive_Polar ( double magnitude , double direction , double rotation ) { } protected static double [ ] normalize ( double [ ] wheelSpeeds ) { } protected static double [ ] rotateVector ( double x , double y , double angle ) { } protected static double limit ( double num ) { } private class SpeedStorage { public double FRONT_LEFT ; public double FRONT_RIGHT ; public double BACK_LEFT ; public double BACK_RIGHT ; public SpeedStorage ( ) { } public SpeedStorage ( double [ ] a ) { } public double [ ] getArray ( ) { } } }

Fix:
trackingStraight = 1 ;