When you attach the bounce()
to the click event then you can use this
in that function, but outside that you need to define the "this". You could use bind, or change this
to your element.
Try this:
var bounce = function() {
var element = $('someID'); // cache it here or outside the function
element.set('tween', {duration: 1500, transition: 'bounce:out'});
element.tween('right', [900, 40]);
}
bounce();
bounce.periodical(10000);