mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 06:18:44 +00:00
Fixed game crash, and improved timer
- Fixed the null pointer exception that happened on slower computers - Made the timer start counting down when the host clicks ready Tags: #story[1109]
This commit is contained in:
@@ -89,7 +89,7 @@ public class GameState implements Runnable {
|
||||
markOrder = new MarkOrder(); //This could be instantiated at some point with a select map?
|
||||
markListeners = new ArrayList<>();
|
||||
|
||||
startTime = System.currentTimeMillis() + 60000;
|
||||
resetStartTime();
|
||||
|
||||
new Thread(this).start(); //Run the auto updates on the game state
|
||||
new Thread(this, "GameState").start(); //Run the auto updates on the game state
|
||||
@@ -149,6 +149,10 @@ public class GameState implements Runnable {
|
||||
return startTime;
|
||||
}
|
||||
|
||||
public static void resetStartTime(){
|
||||
startTime = System.currentTimeMillis() + MainServerThread.TIME_TILL_START;
|
||||
}
|
||||
|
||||
public static Double getWindDirection() {
|
||||
return windDirection;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user