#include "CooldownScene.h" USING_NS_AX; void CooldownScene::continueInit() { UIPackage::addPackage("UI/Cooldown"); _view = UIPackage::createObject("Cooldown", "Main")->as(); _groot->addChild(_view); GProgressBar* btn0 = _view->getChild("b0")->as(); GProgressBar* btn1 = _view->getChild("b1")->as(); btn0->getChild("icon")->setIcon("icons/k0.png"); btn1->getChild("icon")->setIcon("icons/k1.png"); GTween::to(0, 100, 5)->setTarget(btn0, TweenPropType::Progress)->setRepeat(-1); GTween::to(10, 0, 10)->setTarget(btn1, TweenPropType::Progress)->setRepeat(-1); }