java.lang.Object
View.WaitingPageController
- All Implemented Interfaces:
Observer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetIsHost(boolean isHost) The setIsHost function sets the host variable to true or false.voidsetStage(javafx.stage.Stage stage) voidThe setViewModel function is used to set the view model for this class.voidThe startGame function is called when the user clicks on the "Start Game" button.voidupdate(Observable o, Object arg)
-
Constructor Details
-
WaitingPageController
public WaitingPageController()
-
-
Method Details
-
setStage
public void setStage(javafx.stage.Stage stage) -
setViewModel
The setViewModel function is used to set the view model for this class.- Parameters:
vm- Bind the disconnect property to the view model's disconnect property
-
startGame
The startGame function is called when the user clicks on the "Start Game" button. It calls a function in ViewModel to start the game, and then swaps scenes to display the game board.- Throws:
IOException
-
setIsHost
public void setIsHost(boolean isHost) The setIsHost function sets the host variable to true or false.- Parameters:
isHost- Set the host variable to true or false
-
update
-