hello
I am working on a game to be released on Blackberry Playbook using Coocs2dx (1.0.1-x-0.13.0-beta) and Marmalade (5.2).
Almost done with the game…only a last few glitches i am stuck with and would like if someone could help me out with this.
for pausing my in-game I am using
cocos2d::CCDirector::sharedDirector()->pause()
cocos2d::CCDirector::sharedDirector()->resume()
which is working fine
but there are events when I would like to get my game paused, like…
-
The standby timeout set on the playbook device is ON, so after for eg. 1 minute the backlight turns off and the device is on standby mode.
so is there a way or event that i could get at this point to pause my game when the device is on standby mode. (also in standby mode the FPS drops to 1 or 2 fps) -
one of the ways, if a user using the playbook wants to close the app, he has to slide/swipe up so the app gets minimized and then he can close it or let it run in the background.
currently, my game gets minimized, but is still running in the minimized state…what i am looking for is that the game should get minimized and also get paused along with that.
Also i would like to mention that the functions applicationDidEnterBackground and applicationWillEnterForeground are not getting called, i was kind of hoping if these functions got called while minimizing, then the app would have gone in the paused state.
Also, i tried using s3eDeviceRegister(S3E_DEVICE_NOTIFY_PAUSE,(s3eCallback)CMenuScene::pauseCallback, NULL) which works on the simulator when i trigger it manually through (events->simulate suspend)
but not on the device.
Any suggestions would be of great help.
Thank you