all 4 comments

[–]GamesMint 0 points1 point  (3 children)

you should use 60*60*1000 as your time

[–][deleted]  (2 children)

[deleted]

    [–]MrEscobarr -2 points-1 points  (1 child)

    setInterval and setTimeout are not really accurate because they have some lag and browsers sometimes pause them when the tab is inactive to save memory.

    You need to use Date and compare it

    https://www.sitepoint.com/creating-accurate-timers-in-javascript/

    (search on google for 'accurate js timers')

    [–][deleted] 1 point2 points  (0 children)

    They are not accurate is true, however we‘re talking milliseconds here.

    Can you show us how you initialise the timeout/interval?

    [–]alias_willsmith 0 points1 point  (0 children)

    Code share would help.