FIX pauseGame Modal in GameEnd View

This commit is contained in:
Niko Jochim 2020-06-26 02:55:02 +02:00
parent 67c400a069
commit c7aa992790

View File

@ -336,16 +336,18 @@ class GameScene: SKScene{
@objc func pauseGame() -> Void { @objc func pauseGame() -> Void {
entityManager.removeModal() if !GameCenterManager.sharedInstance.gameEnded {
entityManager.getHUD()?.roundTimer.stopTimer() entityManager.removeModal()
entityManager.add(Modal(modaltype: .PauseGame, entityManager.getHUD()?.roundTimer.stopTimer()
base: nil, entityManager.add(Modal(modaltype: .PauseGame,
anchorPoint: CGPoint(x: self.size.width / 2 , y: self.size.height / 2), base: nil,
gameScene: self, anchorPoint: CGPoint(x: self.size.width / 2 , y: self.size.height / 2),
currentDraggedBase: nil, gameScene: self,
touchLocation: nil, currentDraggedBase: nil,
collisionBase: nil touchLocation: nil,
)) collisionBase: nil
))
}
} }
@objc func resumeGame() -> Void { @objc func resumeGame() -> Void {