2
0
mirror of https://github.com/team2059/Dent synced 2024-12-18 20:52:29 -05:00

BinRaise will now only run when held

This commit is contained in:
Austen Adler 2015-03-14 11:24:04 -04:00
parent d06f436f11
commit e82bff8e1b

6
OI.cpp
View File

@ -37,16 +37,14 @@ OI::OI(){
//right8->WhenPressed(new BinCloseArms()); //right8->WhenPressed(new BinCloseArms());
binRaise=new BinRaise(3.0); binRaise=new BinRaise(3.0);
binLower=new BinLower(2.0); binLower=new BinLower(2.0);
right3->WhenPressed(binLower); right3->WhileHeld(binLower);
right3->CancelWhenPressed(binRaise); right3->CancelWhenPressed(binRaise);
right5->WhenPressed(binRaise); right5->WhileHeld(binRaise);
right5->CancelWhenPressed(binLower); right5->CancelWhenPressed(binLower);
// Cancel // Cancel
JoystickButton *right12=new JoystickButton(rightStick, 12); JoystickButton *right12=new JoystickButton(rightStick, 12);
right12->CancelWhenPressed(raise); right12->CancelWhenPressed(raise);
right12->CancelWhenPressed(lower); right12->CancelWhenPressed(lower);
right12->CancelWhenPressed(binRaise);
right12->CancelWhenPressed(binLower);
// Basic motor test // Basic motor test
CheckRobot* checkRobot=new CheckRobot(); CheckRobot* checkRobot=new CheckRobot();
JoystickButton *left7=new JoystickButton(leftStick, 7); JoystickButton *left7=new JoystickButton(leftStick, 7);