<commit_before>package org.firebears.commands.drive;

import org.firebears.Robot;

import edu.wpi.first.wpilibj.command.Command;

/**
 *
 */
public class Totecenter extends Command {

    public Totecenter() {
        // Use requires() here to declare subsystem dependencies
        // eg. requires(chassis);
    	requires(Robot.chassis);
    }

    // Called just before this Command runs the first time
    protected void initialize() {
    }

    // Called repeatedly when this Command is scheduled to run
    protected void execute() {
    	if (Robot.chassis.leftsharpIRRange.getRangefinderDistance() > 20) {
    		Robot.chassis.mechanumDrive(0,-.5,0);
    	}
    	else if (Robot.chassis.rightsharpIRRange.getRangefinderDistance() > 20) {
    		Robot.chassis.mechanumDrive(0, 0,-.5);
    	}
    }

    // Make this return true when this Command no longer needs to run execute()
    protected boolean isFinished() {
        return (Robot.chassis.leftsharpIRRange.getRangefinderDistance() < 20 && Robot.chassis.rightsharpIRRange.getRangefinderDistance() < 20);
    }

    // Called once after isFinished returns true
    protected void end() {
    }

    // Called when another command which requires one or more of the same
    // subsystems is scheduled to run
    protected void interrupted() {
    }
}
<commit_msg>Jacob- Chaged the Totecenter command<commit_after>package org.firebears.commands.drive;

import org.firebears.Robot;

import edu.wpi.first.wpilibj.command.Command;

/**
 *
 */
public class Totecenter extends Command {

    public Totecenter() {
        // Use requires() here to declare subsystem dependencies
        // eg. requires(chassis);
    	requires(Robot.chassis);
    }

    // Called just before this Command runs the first time
    protected void initialize() {
    }

    // Called repeatedly when this Command is scheduled to run
    protected void execute() {
    	if (Robot.chassis.leftsharpIRRange.getRangefinderDistance() > 20 && Robot.chassis.rightsharpIRRange.getRangefinderDistance() > 20) {
    		Robot.chassis.mechanumDrive(0,-.1,0);
    	}
    	else if (Robot.chassis.leftsharpIRRange.getRangefinderDistance() > 20) {
    		Robot.chassis.mechanumDrive(0, 0,.1);
    	}
    	else if (Robot.chassis.rightsharpIRRange.getRangefinderDistance() > 20) {
    		Robot.chassis.mechanumDrive(0,0,-.1);
    	}
    	
    }

    // Make this return true when this Command no longer needs to run execute()
    protected boolean isFinished() {
        return (Robot.chassis.leftsharpIRRange.getRangefinderDistance() < 20 && Robot.chassis.rightsharpIRRange.getRangefinderDistance() < 20);
    }

    // Called once after isFinished returns true
    protected void end() {
    }

    // Called when another command which requires one or more of the same
    // subsystems is scheduled to run
    protected void interrupted() {
    }
}

{'fraction_non_alphanumeric': 0.10097833682739343, 'fraction_numerical': 0.01222921034241789, 'mean_word_length': 2.9819193324061195, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4503286', 'n_tokens_mistral': 936, 'n_tokens_neox': 852, 'n_words': 225}