var ss = new cc.RenderTexture(512, 512);
ss.beginWithClear(255, 0, 0, 255);
// gRenderLayer.visit();
ss.end();
ss.setPosition( (Math.random() - 0.5)*1000, (Math.random() - 0.5)*1000);
var node = cc.find('Canvas')
node.addChild(ss, 200, "");
I can’t add RenderTexture object to node, I’m getting this error:
The child to add must be instance of cc.Node, not TheClass.
RenderTexture object is a TheClass. Also I can’t create cc.Layer in CocosCreator