开发者

How to resume my game after call ended

开发者 https://www.devze.com 2023-01-07 11:16 出处:网络
I have developed a game. When i checked in iphone, i found that my game pause when an incoming call comes and restarts after 开发者_如何转开发attending and ending the call. How to make it resume inste

I have developed a game. When i checked in iphone, i found that my game pause when an incoming call comes and restarts after 开发者_如何转开发attending and ending the call. How to make it resume instead of restart


Try checking the AppDelegate.m for this:

- (void)applicationWillResignActive:(UIApplication *)application {
[[CCDirector sharedDirector] pause];
}

- (void)applicationDidBecomeActive:(UIApplication *)application {
[[CCDirector sharedDirector] resume];
}

That usually "pauses" the current scene when the application is interupted...say for a phone call. If this doesn't help...maybe you could eyplain your problem further. greetings

0

精彩评论

暂无评论...
验证码 换一张
取 消