Reset sketch in p5js

so i’m playing around with p5js and made a ball bounce while at the same time lose momentum after each bounce. I want to be able to make the ball reset after 30 seconds or a minute has passed. So i’m …