I\'ve spent a couple days at this and I give up.
I\'m trying to get an object to animate along a sine wave infinitely. It should not end after the first period.
Change
return {top: y + "px", left: current_x + x + "px"};
to
return {top: y + "px", left: last_x + x + "px"};
See an updated fiddle