title: Objective-C Score counting
body: <p>I have a flappy bird clone in my hands. And I am trying to understand why score is not counted correctly. It sometimes does not register a pipe. I am a total newbie:)</p>
  
  <pre><code>- (void) updateScore:(NSTimeInterval) currentTime
  {
      for(int i=0;i&lt;nbObstacles;i++){
  
          SKSpriteNode * topPipe = (SKSpriteNode *) topPipes[i];
  
          // Score, adapt font size
          if(X(topPipe) + WIDTH(topPipe)/2 &gt; bird.position.x &amp;&amp;
             X(topPipe) + WIDTH(topPipe)/2 &lt; bird.position.x + FLOOR_SCROLLING_SPEED){
              self.score +=1;
              scoreLabel.text = [NSString stringWithFormat:@"%lu",self.score];
              if(self.score&gt;=10){
                  scoreLabel.fontSize = 340;
                  scoreLabel.position = CGPointMake(CGRectGetMidX(self.frame), 120);
              }
          }
      }
  }
  </code></pre>