title: How to track multiple touch events in Libgdx?
body: <p>I am making a racing game using Libgdx. I want to touch the half right side of screen to speed up, at the same time without removing previous touch point touch again another on the left side of the screen to fire a shot.  I am unable to detect later touch points.</p>
  
  <p>I have searched and get <code>Gdx.input.isTouched(int index)</code> method, but cannot determin how to use it. My screen touch code is:</p>
  
  <pre><code>if(Gdx.input.isTouched(0) &amp;&amp; world.heroCar.state != HeroCar.HERO_STATE_HIT){
      guiCam.unproject(touchPoint.set(Gdx.input.getX(), Gdx.input.getY(), 0));
      if (OverlapTester.pointInRectangle(rightScreenBounds, touchPoint.x, touchPoint.y)) {
         world.heroCar.state = HeroCar.HERO_STATE_FASTRUN;
         world.heroCar.velocity.y = HeroCar.HERO_STATE_FASTRUN_VELOCITY;
      }
  } else {
      world.heroCar.velocity.y = HeroCar.HERO_RUN_VELOCITY;
  }
  
  if (Gdx.input.isTouched(1)) {
      guiCam.unproject(touchPoint.set(Gdx.input.getX(), Gdx.input.getY(), 0));
      if (OverlapTester.pointInRectangle(leftScreenBounds, touchPoint.x, touchPoint.y)) {
         world.shot();
      }
  }
  </code></pre>