脚本没有套在Label上时(一般也不会套在Label上…)
如果在 properties里写的是cc.Label(一般就这样写)
properties: {
scoreLabel:cc.Label,
},
这个时候更改Label
this.scoreLabel.string = “更改的字符串”;
如果在 properties里写的是cc.Node
这个时候改Label
this.scoreLabel.getComponent(cc.Label).string=“更改的字符串”;
Label改的不成功也许就是可能是没对应好。。