var sp;
var x = 0;
export default class Scene extends Laya.Sprite{
constructor(){
super();
Laya.init(500, 300, Laya.WebGL);
var bg = new Laya.Sprite();
bg.loadImage("comp/hunter.jpg");
this.addChild(bg);
Laya.timer.frameLoop(1,this,this.move);
// drawSomething();
}
move() {
sp = new Laya.Sprite();
Laya.stage.addChild(sp);
//画曲线
if(x<100){
x++;
}
sp.graphics.clear();
sp.graphics.drawCurves(10, 58, [x, 0, 19, -100, 39, 0], "#ff0000", 3);
}
}
new Scene();