hosts now send info then wait rather than wait then send

#story[1188]
This commit is contained in:
hba56
2017-09-01 12:20:48 +12:00
parent 42ac733d72
commit 5676d435b0
@@ -26,16 +26,15 @@ public class MatchBrowserHostRunnable implements RunnableWithFramePeriod {
long previousFrameTime = System.currentTimeMillis();
while (!Thread.interrupted()) {
long currentFrameTime = System.currentTimeMillis();
waitForFramePeriod(previousFrameTime, currentFrameTime, 10000);
previousFrameTime = currentFrameTime;
try{
matchBrowserInterface.sendOutGameInfo(gameInfo, socket);
}catch (IOException e){
System.err.println("HostGameMessage could not be sent");
}
long currentFrameTime = System.currentTimeMillis();
waitForFramePeriod(previousFrameTime, currentFrameTime, 10000);
previousFrameTime = currentFrameTime;
}
}
}