Adding CCLayer to CCMenu
-
27-06-2021 - |
Question
How can a CCLayer subclass be added to a CCMenu? I have a CCLayer subclass that's like a switch control and I'd like to include in a CCMenu.
Solution
CCMenu manages subclasses of CCMenuItem. You can try inherit your switch from CCMenuItem and override it's activate
method.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow