2014-10-31 48 views
1

在我製作的遊戲中,我想在遊戲每次打開時製作動畫。我正在考慮使用SKScene作爲我的加載場景來顯示動畫。你認爲這是一個好主意,還是有更好的方法去做這件事?使用SKScene作爲加載屏幕

+0

執行它。它工作嗎?是。好。不要因爲這種微不足道的事情而陷於分析癱瘓。 ;) – LearnCocos2D 2014-10-31 18:57:50

回答

-1

SKScenes是Sprite Kit的構建模塊。您可以使用場景內置的功能動畫,延遲和轉換到另一個場景。基本上,在場景過渡到下一個場景時製作一個序列。

// Here is transitioning code which covers a majority of your tasks. 

SKTransition *reveal = [SKTransition flipHorizontalWithDuration:0.5]; 
SKScene * gameOverScene = [[GameOverScene alloc] initWithSize:self.size won:YES]; 
[self.view presentScene:gameOverScene transition: reveal];