Hi all!
I have a class which inherits from CCNode. What I need is function callback which is called every second to process some logic. I decided to use CCTimer, but when I do this:
Thanks for reply. I tried this, it doesn’t work again. Callback is not called. Note that I have manual class which inherits from CCNode. By the way I have another class which inherits from CCLayer, I initialized it and everything works. I don’t understand what is different betwween this two classes.
Something wrong… I inherit my class from CCLayer but callback is not called again. Maybe I need something like run this Layer or initialize or redefine some virtual function…I am confused. For example I have class House which inherits from CCLayer. I create a lot of House objects and call schedule with callback in each constructor. but it is not work. Help please