KTween learning
/**
* Copyright yukifuruyoru ( http://wonderfl.net/user/yukifuruyoru )
* MIT License ( http://www.opensource.org/licenses/mit-license.php )
* Downloaded from: http://wonderfl.net/c/dPLd
*/
package {
import flash.display.Sprite;
import net.kawa.tween.KTween;
import net.kawa.tween.KTJob;
import net.kawa.tween.easing.*;
public class FlashTest extends Sprite {
public function FlashTest() {
var myMC:Sprite=new Sprite;
myMC.graphics.beginFill(0);
myMC.graphics.drawRect(0,0,20,20);
addChild(myMC);
var job:KTJob= KTween.to(myMC, 5, {x: myMC.x+100}, Elastic.easeOut, null);
with(job){
round=true;
yoyo=true;
repeat=true;
}
}
}
}