Scalar field collapse in three-dimensional AdS spacetime