Added a framerate limiter in basictest.js, will be customizable in the future.