void Rotate()
{
Vector3 diff = touchPos[1] - touchPos[0];
angle = (Mathf.Atan2(diff.y, diff.x));
transform.rotation = Quaternion.Euler(0f, 0f ,Mathf.Rad2Deg * angle);
}
how can I make it to only increase/decrease its rotation.
I only need it on z axis.