local gradient_layer = cc.LayerGradient:create()
:setStartColor(cc.c3b(226, 191, 84)) --渐变开始颜色
:setEndColor(cc.c3b(255, 177, 142)) --渐变结束颜色
:setContentSize(640, 1136) --layer大小
:setVector(cc.p(0.5, -0.5)) --渐变方向
:setOpacity(255) --透明度
:addTo(self)
quick-cocos2d-x渐变layer
最新推荐文章于 2024-02-20 13:37:10 发布