I am making an infinite scroller game and I spawn sprites in update() function based on the counter like so:
-(void)update {
_spawnCar += 1;
if (_spawnCar>=500) {
_spawnCar = 0;
[self spawnCar];
}
Inside spawnCar I add the sprite to self and apply Impulse to it once. This code is just a sample, actual code has more spawns, like spawning trees, roads, etc.
I have about 50 sprites at normal play. On device it gives perfect 60fps. But what I don't get is the movement of the car sometimes are jerky/stutter/choppy.
I have no idea what is causing the stutter because I do not update the car position in the update. I just applied impulse once and that's it. Any idea how to check the source of this choppiness movement.
I use SKCameraNode to center on hero character and hero character walks in one direction.