NSTimer vs SKAction (performance)

I'm a bit new to SpriteKit and Game development My question is, is it better to use SKAction like:

SKAction * shelvesAction = [SKAction performSelector:@selector(makeShelves) onTarget:self];
SKAction * delayAction = [SKAction waitForDuration:1];
SKAction * runShelvesForever = [SKAction repeatActionForever:[SKAction sequence:@[delayAction,shelvesAction]]];
[self runAction:runShelvesForever withKey:@"shelvesAction"];

      

Or just NSTimer

_shevesTimer = [NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(makeShelves) userInfo:nil repeats:YES];

      

Which one is faster and what are the differences?

+3
performance ios nstimer skaction


source to share


No one has answered this question yet

Check out similar questions:

2847
Improve SQLite performance per second per second?
1406
Why does changing 0.1f to 0 slow down performance by 10x?
1250
Replacing 32-bit loop counter with 64-bit values ​​leads to crazy performance deviations
870
Swift Beta: Sorting Arrays
778
Java Efficiency "Double Bracket Initialization"?
3
NSTimer memory management issues
2
iPhone: How to keep a timer when iPhone is locked?
0
EXC_BAD_ACCESS - NSZombie catches nothing but NSEnableAutoReleasePool = NO fixes
0
How do I move the UIImageView?
0
Time interval NSTimer



All Articles
Loading...
X
Show
Funny
Dev
Pics