This commit is contained in:
Noah Moroze 2014-05-17 10:24:47 -04:00
commit 0e0a25eaf3

22
main.js
View file

@ -1 +1,21 @@
// main thing here
// main thing here
window.requestAnimFrame = (function(){
return window.requestAnimationFrame ||
window.webkitRequestAnimationFrame ||
window.mozRequestAnimationFrame ||
function( callback ){
window.setTimeout(callback, 1000 / 60);
};
})();
(function animloop(){
requestAnimFrame(animloop);
render();
})();
function render() {
// game code
requestAnimFrame(animloop);
}