I'm transmitting data from Leap-Motion to Arduino through processing. However, it always returns error "java.lang.ArrayIndexOutOfBoundsException:1"

Here's the code that's generating the error but I just don't know what's causing the issue.

```
import processing.serial.*;
Serial myPort;
import com.onformative.leap.LeapMotionP5;
import com.leapmotion.leap.Hand;

LeapMotionP5 leap;
float xhand;
float yhand;
float zhand;

void setup(){
  frameRate(20);
  size(500, 500, P2D);

  myPort = new Serial(this, "COM7", 57600);
  myPort.bufferUntil ('\n');
  leap = new LeapMotionP5(this);
}

void draw(){
background(23,23,200);
ellipse(getHandX()+30, getHandZ()+320, 55, 55);

line( 200, 500, 200, 0);
line( 300, 500, 300, 0);
line( 0, 200, 500, 200);
line( 0, 300, 500, 300);

int handCt = 0;

 for (Hand hand : leap.getHandList()) {
     if (handCt == 0) {
      PVector handPos = leap.getPosition(hand);
      setHandPos( handPos.x, handPos.y, handPos.z );
     }
     handCt++;

    int throttle = (int)map(getHandY(), height-100, -100, 0, 85);
    throttle = constrain(throttle, 0, 85);
    int pitch = (int)map(getHandZ(), -500, 1000, 171, 250);
    pitch = constrain(pitch, 171, 250);
    int yaw= (int)map(getHandX(), width-130, -width, 86, 170);
    yaw = constrain(yaw, 86, 170);
    myPort.write(yaw);
    myPort.write(pitch);
    myPort.write(throttle);
    println(pitch);
  }
}

```