views:

58

answers:

2

Hi, I am writing a small shooting game using cocos2d. It's working good in simulator. But when testing in the device, the animations of sprites are slow and they are stucking. The images I used are CCSprites. And I used CCAnimation for the animation of the images. Why the game acting different in simulator and device ?

Thank you.

A: 

You must test your application on device always to avoid such problems. Applications in simulator are far better in performance than in device, so it is better to test your crucial application functionalities in device always.

Raj
A: 

You might want to check if you are using CCLog - this leads to huge performance drops on the device due to the need to communicate back and forth with the Xcode console.

Alexander Feder
@afeder. I am not using CCLog in my code. I think the problem is with the images I am using. They size is big. I re saved them so that their size decreased by very large amount. So, the performance was now better than before. But, still I need to get the desired speed of animation. I am thinking of using CCSpriteSheet instead of CCSprite. I am following this blog. I think it's good. http://getsetgames.com/2010/04/18/how-to-animate-sprites-in-cocos2d/ Thank you.
srikanth rongali