5秒后开始转换

时间:2015-06-10 19:01:41

标签: swift sprite-kit

您好如何进行转换

perl -nle 'print "$1 $2" while /^($ENV{NAME}_.+rev).+\x27(.+)\x27/g;' $ENVFILE

5秒后开始?

我的代码:

let transitionType = SKTransition.crossFadeWithDuration (2.0)

1 个答案:

答案 0 :(得分:2)

您可以在SKAction.waitForDuration中使用SKAction.runBlockSKAction sequence结合使用:

let wait = SKAction.waitForDuration(5)
let action = SKAction.runBlock {
    view?.presentScene(nextLevel, transition: transitionType)
}

self.runAction(SKAction.sequence([wait, action]))