title: Importance of Cocos2D CCScenes?
body: <p>I recently followed Ray Wenderlich's Cocos2D tutorial for putting Cocos2D in a UIKit app. I am currently only using Cocos2D in only one of my UIViews. In the tutorial he uses a CCScene which is a specific .h and .m class in the project. In the scene is some code which I do not know the important of either. I must say that I am new to Cocos2D and I am wondering what is the point of a CCScene? Do I need to use it in my situation? And if so, how?</p>
  
  <p>Thanks!</p>
  
  <p><strong>Edit1</strong>: Is this correct? I am also adding a simple game loop so should I do it in the way I am doing it below or should I use CADisplayLink?</p>
  
  <pre><code>//Cocos2D methods
  -(id) init {
      if((self=[super init]))
      {
          CCScene *scene = [CCScene node];
          CCLayer *layer = [CCLayer node];
          [scene addChild:layer];
          [[CCDirector sharedDirector] runWithScene:scene];
          [self performSelector:@selector(cocosgameLoop:) withObject:nil afterDelay:1/60.0f];
      }
      return self;
  }
  - (void)cocosgameLoop:(ccTime)dT {
      //Check for collisions here and add gravity, etc....
  }
  - (void)viewDidUnload {
      [super viewDidUnload];
      [[CCDirector sharedDirector] end];
  }
  //
  </code></pre>