Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS SpriteKit Get All nodes in a current scene and make the application universal. [closed]

Hi, I am new to sprite kit framework I just wanted to know two things:


1) How to get all the SKSprite Nodes in a current scene?
2) How to make the application universal i.e it will run on iPhone 3.5", iPhone 4" and on iPad?


Thanks in advance.

like image 268
Aleem Ahmad Avatar asked Mar 19 '14 04:03

Aleem Ahmad


People also ask

What is an image in SpriteKit?

An image, decoded on the GPU, that can be used to render various SpriteKit objects. A collection of textures optimized for storage and drawing performance. A texture whose contents can be dynamically updated. Animate nodes by using a suite of provided actions, or create custom actions.

What can you do with SpriteKit?

Add high-performance 2D content with smooth animations to your app, or create a game with a high-level set of 2D game-based tools. SpriteKit is a general-purpose framework for drawing shapes, particles, text, images, and video in two dimensions.

What is SpriteKit WatchKit?

A visual WatchKit element that displays a SpriteKit scene. Load graphics from various sources, or use an atlas to maximize rendering performance. Speed up image display and enable more images to be displayed at one time. An image, decoded on the GPU, that can be used to render various SpriteKit objects.

How do you draw a SpriteKit scene?

Draw a SpriteKit scene using a rendering object. Compare the different ways to display a SpriteKit scene. A view subclass that renders a SpriteKit scene. An object that renders a scene into a custom Metal rendering pipeline and drives the scene update cycle. A visual WatchKit element that displays a SpriteKit scene.


1 Answers

  1. in Scene.m, you can use self.children to get all the SKSprite Nodes
  2. http://www.raywenderlich.com/49695/sprite-kit-tutorial-making-a-universal-app-part-1
like image 78
jseanj Avatar answered Sep 24 '22 03:09

jseanj