diff --git a/lib/quintus_anim.js b/lib/quintus_anim.js index 6c1960c2..e01c69b2 100644 --- a/lib/quintus_anim.js +++ b/lib/quintus_anim.js @@ -40,7 +40,6 @@ Quintus.Anim = function(Q) { if(p.animationChanged) { p.animationChanged = false; } else { - p.animationTime += dt; if(p.animationTime > rate) { stepped = Math.floor(p.animationTime / rate); p.animationTime -= stepped * rate; @@ -135,8 +134,9 @@ Quintus.Anim = function(Q) { } startX = curX; - endX = Q.width / scale + p.repeatW; - endY = Q.height / scale + p.repeatH; + endX = Q.width / Math.abs(scale) / Math.abs(p.scale || 1) + p.repeatW; + endY = Q.height / Math.abs(scale) / Math.abs(p.scale || 1) + p.repeatH; + while(curY < endY) { curX = startX; while(curX < endX) {