RayXu

Members
  • Content Count

    2
  • Joined

  • Last visited

  1. Thx oh...Turned out to be used... "1 / 60 * delta" or "ticker.deltaMs" This can do what I want! Now I use the following code instead. He should be fine. const seconds = 0; app.ticker.add(delta => { seconds += (1 / 60) * delta; if(seconds >= 0.5 ){ console.log('alert!'); } }); but...pixi-timer I don’t understand how to use? Because I will update the screen through time judgment during recycling. Finally thank you @ivan.popelyshev
  2. How can I run it every second or every 0.5 seconds? I try const seconds = 0; app.ticker.add(delta => { seconds += 1 / 60; if(seconds >= 0.5 ){ console.log('alert!'); } }); There doesn't seem to be a very stable operation.