title: TouchPhase.Ended not executing
body: <p>Working in a mobile controller and I'm having an interesting issue. When I press left and right fast and then jump then the character keeps on walking to either right or left direction making me think that moveLeft or moveRight never get sets to false in some instances. </p>
  
  <p>I read a lot of posts talking about TouchPhase.Ended not firing, have you guys experience this? is there a solution?</p>
  
  <p>Edited my post and included my code guys:</p>
  
  <pre><code>void Update(){
      TouchManager ();
  }
  
  void FixedUpdate() {
      Move ();
  }
  
  void Move ()
  {
      //True if player hits ground
      groundHit = Physics2D.OverlapCircle (groundCheck.position, groundRadius, whatIsGround);
      //True if player hits top
      topHit = Physics2D.OverlapCircle (topCheck.position, topRadius, whatIsTop);
      anim.SetBool ("Ground", groundHit);
      anim.SetFloat ("vSpeed", this.rigidbody2D.velocity.y);
      if (Globals.gameStatus == Globals.GameStatus.Dead) {
          anim.SetFloat ("Speed", 0);
          return;
      }
      float move = 0.0f;
  
      if (moveLeft) {
          move = -1.0f;
      }
      if (moveRight) {
          move = 1.0f;
      }
  
      anim.SetFloat ("Speed", Mathf.Abs (move));
  
      rigidbody2D.velocity = new Vector2 (move * maxSpeed, this.rigidbody2D.velocity.y);
      if (move &gt; 0 &amp;&amp; !facingRight)
          Flip ();
      else
          if (move &lt; 0 &amp;&amp; facingRight)
              Flip ();
  }
  
  void TouchManager ()
  {
  
      if (Input.touchCount &gt; 0) {
          var touchCount = Input.touchCount;
          for (var i = 0; i &lt; touchCount; i++) {
              var touch = Input.GetTouch (i);
              //Debug.Log("FingerID: " + touch.fingerId.ToString());
  
              if (touch.phase == TouchPhase.Began) {
                  //Debug.Log("Touch Began executed for touchID: " + touch.
                  if (guiLeft.HitTest (touch.position, Camera.main))
                      moveLeft = true;
                  if (guiRight.HitTest (touch.position, Camera.main))
                      moveRight = true;
                  if (guiJump.HitTest (touch.position, Camera.main))
                  {
                      Debug.Log("Jump pressed");
                      if (groundHit  &amp;&amp; !stickmanIsDead) {
                          anim.SetBool ("Ground", false);
                          rigidbody2D.AddForce (new Vector2 (0, jumpForce));
                      }
                      //Record start time only once
                      holdJumpDownStartedAt = Time.time;
                  }
              }
              //Fall from Platforms
              if(touch.phase == TouchPhase.Stationary){
                  if (guiJump.HitTest (touch.position, Camera.main)){
                      if(Time.time - holdJumpDownStartedAt &gt; dropPlatformAt){
                          Debug.Log(string.Format("Holded for {0} second :) ",dropPlatformAt.ToString()));
                          holdJumpDownStartedAt = 0.0f;
  
                          #region Falling Keystroke
                          var playerFalling = Physics2D.Linecast (transform.position, groundCheck.position, 1 &lt;&lt; LayerMask.NameToLayer ("Floor-Air"));
                          //Fall Key
                          if (playerFalling)
                              StartCoroutine (Fall ());
                          #endregion
                      }
                  }
              }
              if(touch.phase == TouchPhase.Ended || touch.phase == TouchPhase.Canceled){
                  if (guiLeft.HitTest (touch.position, Camera.main))
                      moveLeft = false;
                  if (guiRight.HitTest (touch.position, Camera.main))
                      moveRight = false;
              }
          }
      }
  }
  </code></pre>