We have a code base that was written and released in 2013, but in iOS 9 the app no longer transitions visibly between SKScene
s when the presentScene:transition:
message is sent to our SKView
. The SKScene
receives the didMoveToView:
message but the scene itself never shows on screen.
Here's what we tried:
Metal
via the Info.plist
[SKTransition transitionWithCIFilter:duration:]
instead of the predefined animationszPosition
UIView
animations (this made our SKNode
s disappear)pausesOutgoingScene
to YES
on the SKTransition
None of the above attempts fixed the issue. Note that everything transitions properly in iOS 8
Here is some sample code that doesn't work:
-(BOOL)presentTitle {
if (!titleSceneLoaded) {
return NO;
}
[skView presentScene:titleScene transition:[SKTransition fadeWithDuration:1.0]];
return YES;
}
Changing it to this makes it work again (without the transitions):
-(BOOL)presentTitle {
if (!titleSceneLoaded) {
return NO;
}
[skView presentScene:titleScene];
return YES;
}
Any suggestions on how to locate/fix/workaround the bug?
We were unable to get SKTransition
to work. We talked to the developer support team, posted on the developer forums, and tried everything posted here.
It is SpriteKit bug exclusive to iOS 9. If anyone else runs into this bug on iOS 9, we switched to custom transitions utilizing UIView animateWithDuration:animations:completion:
.