I now call this method from applicationDidBecomeActive ... to help :-)
In a common header file I have:
#define kAllowCheats 1 // 1 on, 0 off
In my game manager I have this:
-(void)checkDevSettings
{
// Developer notices
if (getenv("NSZombieEnabled") || getenv("NSAutoreleaseFreedObjectCheckEnabled")) {
NSLog(@"NSZombieEnabled/NSAutoreleaseFreedObjectCheckEnabled enabled!");
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Developer Notice"
message:@"NSZombieEnabled is ON!\n* * *\nDisable BEFORE submitting!"
delegate:nil
cancelButtonTitle:@"Okay"
otherButtonTitles:nil];
[alert show];
[alert release];
}
if (kAllowCheats) {
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Developer Notice"
message:@"kAllowCheats is ON!\n* * *\nDisable BEFORE submitting!"
delegate:nil
cancelButtonTitle:@"Okay"
otherButtonTitles:nil];
[alert show];
[alert release];
}
}
This first one I almost submitted an app, the second one; yup went live with my developer / cheat codes active. That wasn't a game center game so it wasn't a real problem but with all the hacking in Game Center games I suppose it could cause you extra work.
No comments:
Post a Comment