You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
611 B
Java

void angleGather(float x, float y, float angle, float armLength) {
arduino.digitalWrite(right, arduino.HIGH);
noFill();
strokeWeight(20); // Controls thickness of blue border
stroke(color(0, 0, 127));
beginShape(); // Draws shape
vertex(convertXCoord(x + armLength*cos(angle*PI/360)), convertYCoord(y + armLength*sin(angle*PI/360)));
vertex(convertXCoord(x), convertYCoord(y));
vertex(convertXCoord(x + armLength*cos(angle*PI/360)), convertYCoord(y - armLength*sin(angle*PI/360)));
endShape();
}