Timer using frameRate and frame counter reliable?

前端 未结 1 1000
独厮守ぢ
独厮守ぢ 2020-12-07 06:49

I\'m using p5js to program an animation with a timer countdown. I set my timer up to be updated each frame within an object that is being animated by the draw() function in

相关标签:
1条回答
  • 2020-12-07 07:00

    Why don't you just use the frameCount variable? More info is available in the reference.

    You could also use the millis() function instead. Again, the reference is your best friend.

    If you still can't get it working, please post a MCVE (or better yet, a CodePen or JSFiddle) that we can run to see the problem.

    0 讨论(0)
提交回复
热议问题