there is a cube and the y rotation of the cube is random. How can i round the rotation to 90 or 180 or 270 or 0(to the nearest number)?
deg = 90 * (int)(deg / 90)
there is a cube and the y rotation of the cube is random. How can i round the rotation to 90 or 180 or 270 or 0(to the nearest number)?
deg = 90 * (int)(deg / 90)