working version with one flip at a time, attempting to create multiple flips at once