Skip to content

Use a more accurate timer than setInterval #15

Description

@pintassilgo

I don't know anything about F.LF's code, I'm just creating this ticket after some reading.

  1. F.LF is performing bad in Firefox since version 55 (mid 2017!), at least on Windows machines:
    https://bugzilla.mozilla.org/show_bug.cgi?id=1683560

  2. It seems that 1 is a thing because "the game relies on setTimeout setInterval for precise frame scheduling. This is not a good idea in general, because by default, the timer resolution on Windows is really bad". Source:
    https://bugzilla.mozilla.org/show_bug.cgi?id=1683560#c5

  3. If Chromium (Blink) based browsers handles this well, Firefox must fix this, of course. But the point made in 2 may still be valid for optimization. Maybe you can get something from here:
    https://stackoverflow.com/questions/196027/is-there-a-more-accurate-way-to-create-a-javascript-timer-than-settimeout

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions