adding a looping ability