Back Stephen Dodd Tech Game Development Blog Code

Javascript web worker set interval game loop

Use a Javascript web worker and setInterval to power a game loop that continues running even when the browser is inactive.

© Stephen Dodd 2022