public void TouchDown(MarshalledTouchEvent mTouch) { fingerId = mTouch.ID; phase = Win8TouchPhase.Began; position = new Vector2(mTouch.x, (Screen.height - mTouch.y + PIXEL_Y_CORRECTION)); _previousPosition = position; touchTime = Time.time; _previousTouchTime = touchTime; }
public void FrameEnd() { if (phase == Win8TouchPhase.Began) phase = Win8TouchPhase.Stationnary; if (phase == Win8TouchPhase.Moved && _previousPosition == position) phase = Win8TouchPhase.Stationnary; if (phase == Win8TouchPhase.Ended) phase = Win8TouchPhase.Inactive; _previousPosition = position; _previousTouchTime = touchTime; }
public void TouchUp(MarshalledTouchEvent mTouch) { phase = Win8TouchPhase.Ended; position = new Vector2(mTouch.x, (Screen.height - mTouch.y + PIXEL_Y_CORRECTION)); touchTime = Time.time; }