如题,想要用代码动态的生成九宫格,大神们有没有办法?
搜到的cc.Scale9Sprite方法不管用的
如题,想要用代码动态的生成九宫格,大神们有没有办法?
搜到的cc.Scale9Sprite方法不管用的
[quote=“13yd, post:2, topic:76232, full:true”]
var xx = _node.get(cc.Sprite).spriteFrame; if(xx){ xx.insetTop = _canshu['insetTop']; xx.insetBottom = _canshu['insetBottom']; xx.insetLeft = _canshu['insetLeft']; xx.insetRight= _canshu['insetRight']; _node.get(cc.Sprite).onEnable(); }