Ask coding questions

← Back to all posts
Clicker game per sec.
firedragondnd (45)

I'm making a clicker game and I want to do clicks per sec. How do I do that?

Answered by Coder100 (17018) [earned 5 cycles]
View Answer
Comments
hotnewtop
Coder100 (17018)

SetInterval is ur friend

setInterval(() => {
  // ur code here
}, 1000);

1000 is 1 second.
It is in milliseconds