unity rotate amount code example Example: transform.rotation = closestTransform.rotation; transform.rotation = closestTransform.rotation;