I have double checked the comas and semicolons and nothing seems weird, but you are welcome to check if you want to.
Code:
#include "WPILib.h"
class Robot: public SampleRobot
{
// robot drive system
RobotDrive ArcadeRobot;
Joystick joy, joy2;
Servo ServoX, ServoY;
double servoIn, servoIn2;
VictorSP intake;
TalonSRX flywheel;
USBCamera cam0;
public:
Robot() :
ArcadeRobot(0,1),
joy(0),
joy2(1),
ServoX(5),
ServoY(4),
intake(3),
flywheel(2),
cam0(0)
{
cam0.SetWhiteBalanceAuto();
cam0.SetExposureAuto();
flywheel.SetSafetyEnabled(false);
intake.SetSafetyEnabled(false);
ArcadeRobot.SetExpiration(0.1);
}
/**
* Runs the motors with arcade steering.
*/
void OperatorControl()
{
while (IsOperatorControl() && IsEnabled())
{
if (joy2.GetRawButton(3))
{
//ShootLowGoal();
intake.Set(-1.0);
}
if (joy2.GetRawButton(5))
{
//ShootHighGoal();
intake.Set(1.0);
}
if (joy2.GetRawButton(4))
{
//ShootLowGoal();
flywheel.Set(-1.0);
}
if (joy2.GetRawButton(6))
{
//ShootHighGoal();
flywheel.Set(1.0);
}
servoIn = (joy.GetY() +1)*0.5;
servoIn2 = (joy.GetX() +1)*0.5;
ServoX.Set(servoIn);
ServoY.Set(servoIn2);
ArcadeRobot.ArcadeDrive(joy2);
Wait(0.005);
}
}
};
START_ROBOT_CLASS(Robot)