版本是最新的。
代码如下
auto rootNode = CSLoader::createNode("MainScene.csb");
auto button=(ui::Button*)rootNode->getChildByTag(8);
button->addTouchEventListener(this, toucheventselector(MyHelloWorldScene::onClick));
addChild(rootNode);
版本是最新的。
代码如下
auto rootNode = CSLoader::createNode("MainScene.csb");
auto button=(ui::Button*)rootNode->getChildByTag(8);
button->addTouchEventListener(this, toucheventselector(MyHelloWorldScene::onClick));
addChild(rootNode);
报错详细信息贴一下
#include “cocostudio/CocoStudio.h”
#include “ui/CocosGUI.h”
using namespace ui;
加上命名空间啊。