Ensure animations reach last frame

This commit is contained in:
Dan Williams 2007-03-13 08:19:50 -04:00
parent ac8805246d
commit c58bb3549f

View File

@ -75,6 +75,10 @@ class Animation(object):
start = self.start
change = self.end - self.start
if time == duration:
# last frame
frame = self.end
else:
if easing == EASE_OUT_EXPO:
frame = change * (-pow(2, -10 * time/duration) + 1) + start;
elif easing == EASE_IN_EXPO: