cc.loader.load(“http://thirdwx.qlogo.cn/mmopen/vi_32/x9VZQPf1n9cDD7qbficpNWYJZOGnfkMywuSG22EcKlHnac0Iol5Xicuic1dR21NACyoq0XEYiawNibvCl83ga9D5ONg/132”, function (err, texture) {
if(err){
console.log(“图片下载失败”, url, err);
return;
}
var sprite = new cc.SpriteFrame(texture);
this.node.getComponent(cc.Sprite).spriteFrame = sprite;
})
自己解决了
