fixed bugs in World refactoring, in main.js

This commit is contained in:
Richard Harrington 2013-08-21 19:18:29 -04:00
parent ba784981cd
commit 4993d9a450

View File

@ -146,7 +146,7 @@
function loop(worlds, interval, callback) {
(function continueLoop(tick) {
if (worlds.isEmpty()) {
if (worlds.finished()) {
return;
}
callback();
@ -179,7 +179,7 @@
});
loop(worlds, frameDuration, function() {
debugAnimationCounter++;
canvas.drawWorld(worlds.getCurrentWorld());
canvas.drawWorld(worlds.getPreviousWorld(), worlds.getCurrentWorld());
});
loop(worlds, 1000, function() {
debugSecondsCounter++;