Commit cc3d6281 authored by bogdanbear's avatar bogdanbear

Preparing the field for broken connections....

parent 51158618
......@@ -107,6 +107,7 @@ public class DummyLocalGameLoop extends Thread{
return isPlaying;
}
//default visibility for the getter, should be inaccessible to entities etc.
public synchronized NetworkConnection getNetworkConnection()
{
return networkConnection;
......@@ -133,7 +134,7 @@ public class DummyLocalGameLoop extends Thread{
//System.out.println("DummyLocalGameLoopThread, game is "+isPlaying);
if (getIsPlaying()) {
//initially this is false!
setShouldRPC(false);
//setShouldRPC(false);
LOGGER.info("DummyLocalGameLoopThread,"+currentThread().getId()+ "game is "+isPlaying);
Event eventToReceive = null;
LOGGER.info("The game is on!");
......@@ -178,4 +179,5 @@ public class DummyLocalGameLoop extends Thread{
public synchronized void setShouldRPC(boolean shouldRPC) {
this.shouldRPC = shouldRPC;
}
}
......@@ -45,7 +45,7 @@ public class ServerAddressPanel extends MenuPanel{
String address = addressTextField.getText();
RPCClient.setIp(address);
//it should start RPC calls
DummyLocalGameLoop.getInstance().setShouldRPC(true);
//DummyLocalGameLoop.getInstance().setShouldRPC(true);
getGraphicsMaster().changeGUIStateTo(GraphicsMaster.GUIStates.MULTIPLAYER_MENU);
RPCClient.connect();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment