function rotate() {
        undraw()
        currentRotation++
        if(currentRotation === current.length ) { // if the current rotation is the last one go back to beginning
            currentRotation = 0
        }
        current = theTetraminos[random][currentRotation]
        draw()
    }
// rotate the tetramino by moving to next item in array
rotate the tetramino by moving to next item in array
rotate the tetramino by moving to next item in array
function rotate() {
        undraw()
        currentRotation++
        if(currentRotation === current.length ) { 
            currentRotation = 0
        }
        current = theTetraminos[random][currentRotation]
        draw()
    }
function rotate ( ) { undraw ( ) currentRotation ++ if ( currentRotation === current . length ) { currentRotation = 0 } current = theTetraminos [ random ] [ currentRotation ] draw ( ) }
rotate the tetramino by moving to next item in array
rotate the tetramino by moving to next item in array
// if the current rotation is the last one go back to beginning