CCAnimationの遅延をどのように変更できますか?CCAnimationでの遅延の変更
_monstrAnim = [CCAnimation animationWithFrames:monstrAnimFrames delay:0.1f];
self.monstr = [CCSprite spriteWithSpriteFrameName: [NSString stringWithFormat:@"monstr_%d_1.png", currentLevel]];
self.walkAction = [CCRepeatForever actionWithAction:[CCAnimate actionWithAnimation:_monstrAnim restoreOriginalFrame:NO]];
[self.monstr runAction:self.walkAction];
[monstrSpriteSheet addChild:self.monstr z:1];
これは正常に動作しますが、私はFPSの速度を変更し、私がすべき...
[self.monstr stopAllActions]; [self.monstr runAction:self.walkAction]; [self.monstrAnim setDelay:1];
が、何も起こらなかった...
いつ2番目のコードを実行していますか? CCAnimationを保持しない限り、実行されると解放される可能性があります。 – jonsibley