static void HandleInput(TouchState state, ref Vector2 move)
{
if ((move.magnitude < minMovMagnitude) || (touchState == TouchState.Stationary))
{
//Debug.Log( "CLICK" );
}
else if (touchState == TouchState.Move)
{
move.Normalize();
// Left
if(Mathf.Abs(move.x) > Mathf.Abs (move.y))
{
if(move.x > 0.0f)
{
//Debug.Log( "SWIPE: LEFT" );
}
else
{
//Debug.Log( "SWIPE: RIGHT" );
}
}
// Right
else
{
if(move.y > 0.0f)
{
//Debug.Log( "SWIPE: DOWN" );
}
else
{
//Debug.Log( "SWIPE: UP" );
}
}
}
}