@swap wrote:
Hello,
I've just migrated our game to the last version of cocos-x but I encounter interesting problem with Node::setPosition() methods.In my code I overrides only setPosition(Point) version so far. Now we have another version setPosition(x, y).
The first version with Point(or Vec2) just call the second version (x, y). But for example some Actions calls (x, y) version so when I override Vec2, my version is not called from actions (instead x, y).
So what is purpose to have Vec2 version virtual and overridable? It would be much safer when this helper method (Vec2) is not overridable (or non virtual) and just call virtual real implementation (x, y) .
Thanks for help.
Jiri
Posts: 3
Participants: 3