Add flag(--no-matchmaking) to prevent matchmaking process and instantly open GameScene

This commit is contained in:
Simon Kellner 2020-05-05 18:06:21 +02:00
parent 350682cf82
commit 084b79a7c0

View File

@ -21,7 +21,11 @@ class MenuScene: SKScene {
text: "Start Game",
position: CGPoint(x: midX, y: midY),
onButtonPress: {
if CommandLine.arguments.contains("--no-matchmaking") {
self.loadScene(scene: GameScene(size: self.size))
} else {
MatchmakingHelper.sharedInstance.presentMatchmaker(scene: self)
}
}))
entityManager.add(Button(name: "settingsButton",
iconName: "",