iOS Coder Skills with Sprite Kit and SKNode
Delve into the world of iOS coding through Sprite Kit, SKNode, SKSpriteNode, and more. Learn about creating textures, handling touch events, and utilizing SKActions to enhance your app development skills.
Download Presentation

Please find below an Image/Link to download the presentation.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.
You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.
E N D
Presentation Transcript
Ios7 ios_coder@126.com
Sprite Kit cocos 2d ios OPENGL
Sprite kit SKView SKScene SKNode SKSpriteNode
SKNode SKSpriteNode SKScene SKView
SKTexture + (SKTexture *)textureWithImageNamed:(NSString *)name + (SKTexture *)textureWithRect:(CGRect)rect inTexture:(SKTexture *)texture + (SKTexture *)textureWithCGImage:(CGImageRef)image
SKTextureAtlas + (SKTextureAtlas *)atlasNamed:(NSString *)name - (SKTexture *)textureNamed:(NSString *)name
SKNode + (instancetype)node Position - (void)addChild:(SKNode *)node xScale (void)removeFromParent yScale (void)removeAllActions Alpha - (BOOL)containsPoint:(CGPoint)p Paused Hidden userInteractionEnabled Parent Children
SKSpriteNode anchorPoint size + (instancetype)spriteNodeWithTexture:(SKTexture *)texture size: + (instancetype)spriteNodeWithTexture:(SKTexture *)textureSKNode + (instancetype)spriteNodeWithImageNamed:(NSString *)name + (instancetype)spriteNodeWithColor:(SKColor *)color size:(CGSize)size
SKScene Y anchorPoint 0,0 X
-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event -(void)touchesCancelled:(NSSet *)touches withEvent:(UIEvent *)event -(void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event -(void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event UITouch locationInNode CGRectIntersectsRect(CGRect rect1, CGRect rect2) CGRectContainsRect(CGRect rect1, CGRect rect2) CGRectContainsPoint(CGRect rect, CGPoint point)
SKAction + (SKAction *)moveTo:(CGPoint)location duration:(NSTimeInterval)sec + (SKAction *)sequence:(NSArray *)actions + (SKAction *)group:(NSArray *)actions + (SKAction *)playSoundFileNamed:(NSString*)soundFile waitForCompletion:(BOOL)wait + (SKAction *)repeatActionForever:(SKAction *)action + (SKAction *)waitForDuration:(NSTimeInterval)sec + (SKAction *)animateWithTextures:(NSArray *)textures timePerFrame:(NSTimeInterval)sec