Well I suppose that's the problem - setting the Framerate in the active/inactive notifications - that's introduced for some pause behavior i can't remember at the moment.
(I think it was discussed here in the forum)
So the solution is quite simple:
- set the framerate and then start the engine like this:
- (void)applicationDidFinishLaunching:(UIApplication *)application
{
SP_CREATE_POOL(pool);
[SPStage setSupportHighResolutions:YES];
Game *game = [[Game alloc] initWithWidth:320.0f height:480.0f];
sparrowView.stage = game;
sparrowView.frameRate = 30;
[sparrowView start];
[window makeKeyAndVisible];
[game release];
[SPAudioEngine start];
SP_RELEASE_POOL(pool);
}
- Ask if the engine is already running in become active notification like this:
- (void)applicationDidBecomeActive:(UIApplication *)application
{
if(![sparrowView isStarted])
{
sparrowView.frameRate = 30;
[sparrowView start];
}
}
3. In become inactive notification, first stop the engine and then set the framerate:
- (void)applicationWillResignActive:(UIApplication *)application
{
[sparrowView stop];
sparrowView.frameRate = 5;
}
After implementing this changes, the games behaves as before - but without showing the error.