Skip to main content

Posts

Showing posts from December, 2015

dealing with textureAtlas and spritekit all about preloading texture atlas and remove them when you not need them anymore

spritekit is a cool 2d framework designed by apple with support fast 2d graphics rendering one of the killer feature of sprite kit is texture atlas a what is a texture atlas https://developer.apple.com/library/ios/recipes/xcode_help-texture_atlas/_index.html working with texture atlas in sprite kit is very easy. example #import "GameScene.h" @implementation GameScene {     UIImage *defaultImg;     int MCrow;     int MCcoloum;     float imgWidth;     float imgHeight;     NSArray *atlasArray;     NSMutableArray *fetchedAtlas;     NSDictionary *dict1;     NSDictionary *dict2;     NSDictionary *dict3;     NSDictionary *dict4;     NSDictionary *dict5;     NSDictionary *dict6;     NSDictionary *dict7;     SKSpriteNode *node; } -( void )didMoveToView:( SKView *)view { ...