this.starSprite1 = new cc.Sprite(res.Stars02_png);
//写法1
this.starSprite1.attr({
x: 975,
y: size.height-27,
});
this.addChild(this.starSprite1, 0);
写法2
//this.starSprite.setPosition(size.width / 2,size.height / 2);
写法3
// this.starSprite.setPosition(1012,27);
默认是中心位置,所以这个是可写可不写
//this.starSprite.setAnchorPoint(0.5,0.5);