I noticed the iphone goes to sleep fairly quickly after you stop touching the screen during my game play. Is this normal? It was probably just a minute or 2 at the most.
You can change how long it takes your iPhone to fall asleep/lock in the settings. If you want it only for your game, check the documentation for UIApplication's idleTimerDisabled property. I believe you'd want to set it to yes if you don't want the screen to lock. Oh, fine, I'll just post it here .
A Boolean value that controls whether the idle timer is disabled for the application.
@property(nonatomic, getter=isIdleTimerDisabled) BOOL idleTimerDisabled
The default value of this property is NO. When most applications have no touches as user input for a short period,
the system puts the device into a â€œsleepâ€ state where the screen dims. This is done for the purposes of conserving
power. However, applications that don't have user input except for the accelerometerâ€”games, for instanceâ€”can,
by setting this property to YES, disable the â€œidle timerâ€ to avert system sleep.
Important: You should set this property only if necessary and should be sure to reset it to NO when the need no
longer exists. Most applications should let the system turn off the screen when the idle timer elapses. The only
applications that should disable the idle time are mapping applications, games, or similar programs with
sporadic user interaction in the form of touches.
Ok I guess ill leave it as user configurable. I don't want to turn it right off. Thanks for the info.
Possibly Related Threads...
|Sleep Mode never interrupting my game||Madrayken||4||3,410||
Jul 13, 2009 07:17 AM
Last Post: Madrayken
|Timer Slows down in sleep mode||chrism||13||7,147||
Jun 14, 2009 05:36 PM
Last Post: longjumper