无限重复动作-新手引导箭头上下移动
来源:未知 责任编辑:责任编辑 发表时间:2013-11-26 22:13 点击:次
让箭头上下无限重复移动的方法:
p>
p>
p>
p>
p>
p>
p>
CCSprite *arrow = CCSprite::createWithSpriteFrameName("ug_arrow");
if (arrow)
{
arrow->setAnchorPoint(info.arPoint);
arrow->setPosition(ccp(info.centerPos.x, info.centerPos.y+80));
this->addChild(arrow, 10);
// TODO:让箭头重复上下移动
CCMoveBy *move = CCMoveBy::create(0.3f, ccp(0, 10));
arrow->runAction(CCRepeatForever::create(static_cast<CCSequence *>(CCSequence::create(move, move->reverse(), NULL))));
}
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 进入详细评论页>>

![cocos2d_x+lua[2]](/uploads/allimg/131030/110J64609-0-lp.jpg)








