版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/themagickeyjianan/article/details/87693358
cards.forEach(function (value, index, arr) {
var comp = self.getPoolCard().getComponent("Card")
comp.init(value);
comp.setIndex(-1);
comp.small();
comp.node.x = (index * 30);
comp.node.y = 0;
self.nodOuts.addChild(comp.node);
});