   }
 }
 
+bool direction = true;
+int leftTurns = 0;
+int rightTurns = 0;
+
 void naviguessMaze(double swagSpeed) {
-	bool frontTriggered = false;
-	bool leftTriggered = false;
-	bool rightTriggered = false;
-	bool backTriggered = false;
-	bool sweetSpot =  false;
-	
-	if (frontUltrasonic.getDistance() < 2) {
-		frontTriggered = true;
-	} else if ((leftUltrasonic.getDistance() > 3) && (rightUltrasonic.getDistance() > 4)) {
-		sweetSpot = true;
-	} else if (leftUltrasonic.getDistance() < 3) {
-		leftTriggered = true;
-		frontTriggered = frontUltrasonic.getDistance() < 2;
-	} else if (rightUltrasonic.getDistance() < 3) {
-		rightTriggered = true;
-		frontTriggered = frontUltrasonic.getDistance() < 2;
-	} else if (backUltrasonic.getDistance() < 2) {
-		backTriggered = true;
-	} else {
-		frontTriggered = leftTriggered = rightTriggered = backTriggered = sweetSpot = false;
-	}
-	
-	if (sweetSpot) {
-		hDrive(swagSpeed, 0.0, 0.0);
-	} else if (leftTriggered && frontTriggered) {
+	bool frontTriggered = frontUltrasonic.getDistance() < 2;
+	bool leftTriggered = leftUltrasonic.getDistance() < 3;
+	bool rightTriggered = rightUltrasonic.getDistance() < 3;
+	bool backTriggered = backUltrasonic.getDistance() < 2;
+	
+	// bool sweetSpot =  false;
+	
+	// if (frontUltrasonic.getDistance() < 2) {
+		 // frontTriggered = true;
+	// } 
+	// // else if (leftUltrasonic.getDistance() > 3) && (rightUltrasonic.getDistance() > 4)) {
+		// // sweetSpot = true;
+	// } else if (leftUltrasonic.getDistance() < 3) {
+		// leftTriggered = true;
+		// frontTriggered = frontUltrasonic.getDistance() < 2;
+	// } else if (rightUltrasonic.getDistance() < 3) {
+		// rightTriggered = true;
+		// frontTriggered = frontUltrasonic.getDistance() < 2;
+	// } else if (backUltrasonic.getDistance() < 2) {
+		// backTriggered = true;
+	// } else {
+		// frontTriggered = leftTriggered = rightTriggered = backTriggered = sweetSpot = false;
+	// }
+	
+	// if (sweetSpot) {
+		// hDrive(swagSpeed, 0.0, 0.0);
+	  if (leftTriggered && frontTriggered) {
 		hDrive(-swagSpeed, 0.0, 0.0);
-		delay(50);
+		delay(100);
 		// hDrive(0.0, swagSpeed , 0.0);
-		turnToAngle(90, -swagSpeed);
+		
+		if (rightTurns == 4) {
+			turnToAngle(-90, swagSpeed);
+			rightTurns = 0;
+		} else {
+			turnToAngle(90, -swagSpeed);
+			rightTurns++;
+		}
 	} else if (rightTriggered && frontTriggered) {
 		hDrive(-swagSpeed, 0.0, 0.0);
-		delay(50);
+		delay(100);
 		// hDrive(0.0, -swagSpeed , 0.0);
-		turnToAngle(-90, swagSpeed);
+		
+		if (leftTurns == 4) {
+			turnToAngle(-90, -swagSpeed);
+			leftTurns = 0;
+		} else {
+			turnToAngle(-90, swagSpeed);
+			leftTurns++;
+		}
 	} else if (leftTriggered && !frontTriggered) {
 		hDrive(swagSpeed - 0.2, -swagSpeed, 0.0);
 	} else if (rightTriggered && !frontTriggered) {

	}
	
	foundFlame = true;
	
	fan_motor.set(1.0);
	

void driveToWhite();
void driveThroughRoom();
void hDrive(double move, double rotate, double strafe);
void tankDrive(double leftSpeed, double rightSpeed, double strafeSpeed);
void definedStartSearch();
double getAngle(double targetAngle);
double getPercentError(double actual, double target);
