Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>From the <a href="https://developer.apple.com/library/ios/#documentation/Cocoa/Reference/Foundation/Classes/nstimer_Class/Reference/NSTimer.html" rel="nofollow noreferrer">NSTimer</a> documentation...</p> <blockquote> <p>A timer is not a real-time mechanism; it fires only when one of the run loop modes to which the timer has been added is running and able to check if the timer’s firing time has passed. Because of the various input sources a typical run loop manages, the effective resolution of the time interval for a timer is limited to on the order of 50-100 milliseconds. If a timer’s firing time occurs during a long callout or while the run loop is in a mode that is not monitoring the timer, the timer does not fire until the next time the run loop checks the timer. Therefore, the actual time at which the timer fires potentially can be a significant period of time after the scheduled firing time.</p> </blockquote> <p>Your timer resolution is 10 milliseconds, so if the run loop doesn't not complete quickly enough (under 10 milliseconds), you'll start to notice a lag between real-time, and your counters.</p> <p>If you are implementing a game, devs will generally try to disassociate from the CPU or clock speed.</p> <p>Take a look at this <a href="https://stackoverflow.com/questions/1351234/how-make-a-game-loop-on-the-iphone-without-using-nstimer">answer</a></p> <p>or take a look at how a framework like <a href="http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:best_practices" rel="nofollow noreferrer">cocos2d</a> implements its own scheduler. </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload