I am using the sprite frame cache to upload plists,and sprite-sheets,to use for animation . i have 2 approaches to that and i am sure that one of them is wrong .
i have to load everything i can to cache at the start because it takes time, so at the start of the scene i load all what i need to the close future .(but now my cache is full! )
cache should stay as empty as i can , so i am loading to cache at the moment i start the animation (it takes some time isn't it ? i think it flicks my game ) , and remove it at the same moment i am done with it . (now cache is not full but i have to load/reload many times.)
do i have to take care to remove the unused sprites from cache every time ?
load to cache is :
[[CCSpriteFrameCache sharedSpriteFrameCache] removeSpriteFrameByName:@"stopAnim.plist"];
removing unused is :
[[CCSpriteFrameCache sharedSpriteFrameCache] removeUnusedSpriteFrames];
i can see in my iPad that the system is trying to remove unused sprites and have problems. whats exactly the way to work ?