Hello everyone,
I have a problem with cocos2dx 3.6: I have a snipset of code like this:
Sprite* spr = Sprite::create(“Text-Go.png”);
Sprite* spr1 = Sprite::create(“btn_back.png”);
addChild(spr);
spr->addChild(spr1);
spr->setPosition(Vec2(400, 240));
the expect result are spr and spr1 in position ( 400, 240 ) on the screen,
but now, spr in position( 400, 240 ) on the screen, and spr1 in position( 0, 0 ) on the screen.
Actually, the child is always at the top left corner of parent. event i set the parent node’ s anchor is (0.5,0.5),
I found the thread for this problem:
i tried it, but it does not work.
p/s i have a game on cocos2dx 3.2, i am tring to compile it on cocos2dx 3.6( for windows 10 ). the game is working now, but the sprite, and widget position are incorrect, the above code is just for testing, i dont know that bug is from the engine or my code. one more thing, i am using windows 10
Any help will be appriciated,
Thanks
noone saw this bug before?
Hi, i think i have same problem. have you solved this?
hi @slavikus,
I did not resolve it, i used Widget instead of
here is my isue - Child node wrong position
but in my case I used no default camera