Standardize code

This commit is contained in:
yinkaile 2013-06-08 12:14:43 +08:00
parent cba46082ce
commit 8ff088da53
1 changed files with 4 additions and 2 deletions

View File

@ -309,7 +309,8 @@ std::string TestPerformance::subtitle()
} }
void TestPerformance::addArmature(cocos2d::extension::CCArmature *armature) void TestPerformance::addArmature(cocos2d::extension::CCArmature *armature)
{ {
addChild(armature, armatureCount++); armatureCount++;
addChild(armature, armatureCount);
} }
void TestPerformance::update(float delta) void TestPerformance::update(float delta)
{ {
@ -479,7 +480,8 @@ std::string TestParticleDisplay::subtitle()
} }
bool TestParticleDisplay::ccTouchBegan(CCTouch *pTouch, CCEvent *pEvent) bool TestParticleDisplay::ccTouchBegan(CCTouch *pTouch, CCEvent *pEvent)
{ {
animationID = (++animationID) % armature->getAnimation()->getMovementCount(); ++animationID;
animationID = animationID % armature->getAnimation()->getMovementCount();
armature->getAnimation()->playByIndex(animationID); armature->getAnimation()->playByIndex(animationID);
return false; return false;
} }