mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 14:28:43 +00:00
WIP: Worked on new server thread class that would create and store multiple THREADS of connections. Researched Authorative server structures.
Fixed the current structure of the server to work with the old StreamReciever style and hook up to the Stream Parser tags: #story[1047] pair[wmu16, mra106]
This commit is contained in:
@@ -2,13 +2,13 @@ package seng302.controllers;
|
||||
|
||||
import javafx.fxml.FXML;
|
||||
import javafx.fxml.FXMLLoader;
|
||||
import javafx.scene.Parent;
|
||||
import javafx.scene.control.TextField;
|
||||
import javafx.scene.layout.AnchorPane;
|
||||
import javafx.scene.layout.GridPane;
|
||||
import javafx.scene.layout.Pane;
|
||||
import seng302.gameServer.GameServerThread;
|
||||
import seng302.gameServer.GameState;
|
||||
import seng302.gameServerWithThreading.MainServerThread;
|
||||
import seng302.models.stream.StreamReceiver;
|
||||
|
||||
import java.io.IOException;
|
||||
@@ -61,12 +61,10 @@ public class StartScreenController {
|
||||
try {
|
||||
String ipAddress = InetAddress.getLocalHost().getHostAddress();
|
||||
new GameState(ipAddress);
|
||||
GameServerThread gameServerThread = new GameServerThread("Game Server");
|
||||
System.out.println("Server thread started");
|
||||
|
||||
new MainServerThread().start();
|
||||
// get the lobby controller so that we can pass the game server thread to it
|
||||
LobbyController lobbyController = (LobbyController) setContentPane("/views/LobbyView.fxml");
|
||||
lobbyController.setGameServerThread(gameServerThread);
|
||||
setContentPane("/views/LobbyView.fxml");
|
||||
|
||||
|
||||
} catch (UnknownHostException e) {
|
||||
System.err.println("COULD NOT FIND YOUR IP ADDRESS!");
|
||||
|
||||
Reference in New Issue
Block a user