Host starts with button in ConnectionController

- Converted Event to Singleton for configuring and hosting no more than one game instance.
- Retrieve address and port from ConnectionAcceptor
- Automatically add local host to host list

#story[1010]
This commit is contained in:
Connor Taylor-Brown
2017-07-25 15:52:53 +12:00
parent a27c16d413
commit 7e3e865563
7 changed files with 108 additions and 98 deletions
@@ -15,6 +15,11 @@ public class RaceConnection {
private final int port;
private final StringProperty status;
/**
* Constructor for remote host connections.
* @param hostname URL for remote host
* @param port port for game feed
*/
public RaceConnection(String hostname, int port) {
this.hostname = new SimpleStringProperty(hostname);
this.port = port;