Skip to content

Conversation

WebsiteDeveloper
Copy link

I changed the speed generation to Math.round(o.duration/times) to ensure that the given amount of time is the time the animation takes to complete.

…shakes

I changed the speed generation to Math.round(o.duration/times) to ensure that the given amount of time is the time the animation takes to complete.
@@ -22,7 +22,7 @@ $.effects.effect.shake = function( o, done ) {
distance = o.distance || 20,
times = o.times || 3,
anims = times * 2 + 1,
speed = o.duration,
speed = Math.round(o.duration/times),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That should be divided by anims, not times.

@scottgonzalez
Copy link
Member

Thanks, landed in dec9c54.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants