Moved boat velocity to starting list

Tags: #fix
This commit is contained in:
Michael Rausch
2017-03-08 13:28:00 +13:00
parent 88167773dd
commit bc6762d2dd
3 changed files with 7 additions and 4 deletions
+2
View File
@@ -175,3 +175,5 @@ local.properties
# Code Recommenders
.recommenders/
Makefile
+1 -2
View File
@@ -93,8 +93,7 @@ public class Event {
*/
public String getEventString(){
String currentHeading = Integer.toString(this.getLeg().getHeading());
String velocityKnots = String.format("%1.2f", this.getBoat().getVelocity() * 1.943844492); // Convert meters/second to knots
return (this.getTimeString() + ", " + this.getBoat().getTeamName() + " passed " + this.getLeg().getMarkerLabel() + " going heading " + currentHeading + " at " + velocityKnots + " knots.");
return (this.getTimeString() + ", " + this.getBoat().getTeamName() + " passed " + this.getLeg().getMarkerLabel() + " going heading " + currentHeading + "°");
}
}
+3 -1
View File
@@ -113,7 +113,9 @@ public class Race {
System.out.println("######################");
for (int i = 0; i < numberOfBoats; i++) {
System.out.println(boats[i].getTeamName());
String velocityKnots = String.format("%1.2f", boats[i].getVelocity() * 1.943844492);
System.out.println(boats[i].getTeamName() + " Velocity: " + velocityKnots);
}
}