Bezier Recursive turned into function