My HTML5 game pauses from time to time, how can I find out if it’s a garbage collection problem?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
for Chrome, you can check the Timeline tag in console and check the memory usage. If you see a big Zig-Zag pattern, that likely mean the GC is causing the stuttering.
Also this article goes in depth with how to optimize javascript game
http://www.scirra.com/blog/76/how-to-write-low-garbage-real-time-javascript