android game control
<p>Help me with control in my adnroid game)</p>

<p>I have 2 buttons: 
to move left and to move right. If we press left sprite moves left and if we press right sprite moves.</p>

<p>Here is code:</p>

<pre><code>public boolean onTouchEvent(MotionEvent event) {
    if (event.getAction() == MotionEvent.ACTION_DOWN ||
                event.getAction() == MotionEvent.ACTION_MOVE){ 
        touchX = event.getX();
    }
    if(touchX == arrow_leftX){
        gameLoopThread.setRunning(false);
    }
    else if(touchX == arrow_leftX){
        playerX = playerX - xSpeed;
    }
    else if(touchX == arrow_rightX){
        playerX = playerX - xSpeed;
    }
    else if(touchX == arrow_rightX){
        gameLoopThread.setRunning(false);
    }
    return super.onTouchEvent(event);
} 
</code></pre>

<p><strong>So the Problem is:</strong></p>

<blockquote>
  <p>it moves only left, i dont know how to move right ?</p>
</blockquote>
