Reputation: 1480
all I am making a game in cocos2d, and I am moving an object from one place to another , throught CCTouchBegan , CCTouchMoved, CCTouchEneded (ccp function) and after that I take the action on it. Any thoughts on why this code runs slow on device but fast on simulator in iphone.
Upvotes: 1
Views: 623
Reputation: 1059
check your memory allocations.
am also having same problem. bcoz of memory management . now i solved.
check your memory leakage using performance tool in your xcode.
Upvotes: 0
Reputation: 73936
Code often runs slower on the device than it does in the simulator. The simulator is not accurate with respect to performance. In order to gauge how fast something executes, you have to try it on a device.
Upvotes: 0
Reputation: 570
Show us the code then we can say something particular. But I think you just forgot to stop the action. [object stopAction]; or can use this method [self removeChild:(CCSprite*)sender cleanup:YES] It will also cleanup all running actions depending on the cleanup parameter
Upvotes: 1