DrawNode visit() not available in cocos2d-x metal

Drawnode visit does not compile. Gives the following error:

Tested on one of cpp-test classes.

@zhangxm

I created an issue to track it. Thanks for reporting, you can just create an issue directly in future.

It is also can not work with v3. So may be you use very old engine version. It is because there are two visit() in Node:

virtual void visit(Renderer *renderer, const Mat4& parentTransform, uint32_t parentFlags);
virtual void visit() final;

And we suggest using visit(Renderer *renderer, const Mat4& parentTransform, uint32_t parentFlags) now. If you still want to use old way, you should do it like

d->Node::visit();
1 Like

Cocos version i used was 3.15.1. Thanks for the suggestion on how to use old visit.

In case i want to use new visit, can you give me an easy example on how tofill the parameters required?

You can refer the codes. It is always invoke in draw or visit.