mirror of
https://github.com/michaelrausch/Party-Parrots-At-Sea.git
synced 2026-05-09 14:28:43 +00:00
Started work on start screen
- Server now sends out race start status messages during lobby & pre-start stages - Added timer in lobby Tags: #story[1109]
This commit is contained in:
@@ -20,7 +20,7 @@ public class RaceState {
|
||||
private long raceTime;
|
||||
private long expectedStartTime;
|
||||
private boolean isRaceStarted = false;
|
||||
// long timeTillStart;
|
||||
long timeTillStart;
|
||||
|
||||
public RaceState() {
|
||||
}
|
||||
@@ -38,8 +38,7 @@ public class RaceState {
|
||||
}
|
||||
|
||||
public void updateState (RaceStartData data) {
|
||||
// this.timeTillStart = data.getRaceStartTime();
|
||||
System.out.println(data.getRaceStartTime());
|
||||
this.timeTillStart = data.getRaceStartTime();
|
||||
}
|
||||
|
||||
public String getRaceTimeStr () {
|
||||
@@ -50,6 +49,10 @@ public class RaceState {
|
||||
return (expectedStartTime - raceTime) / 1000;
|
||||
}
|
||||
|
||||
public String getTimeTillStartStr () {
|
||||
return DATE_TIME_FORMAT.format(getTimeTillStart() * 1000);
|
||||
}
|
||||
|
||||
public double getWindSpeed() {
|
||||
return windSpeed;
|
||||
}
|
||||
|
||||
@@ -18,10 +18,10 @@ public class Regatta {
|
||||
private Integer utcOffset;
|
||||
private Double magneticVariation;
|
||||
|
||||
public Regatta(String name, Double latitude, Double longitude) {
|
||||
public Regatta(String name, String courseName, Double latitude, Double longitude) {
|
||||
this.name = name;
|
||||
this.id = DEFAULT_REGATTA_ID;
|
||||
this.courseName = name;
|
||||
this.courseName = courseName;
|
||||
|
||||
this.latitude = latitude;
|
||||
this.longitude = longitude;
|
||||
|
||||
Reference in New Issue
Block a user