Display team name and speed beside boat

- Also slowed down the AnimationTimer
- Removed the need to scale the canvas

Tags: #implement #story[18] #story[19]
This commit is contained in:
Michael Rausch
2017-03-23 18:04:00 +13:00
parent a91b2b4f7e
commit 403aaa76ae
3 changed files with 45 additions and 25 deletions
+4
View File
@@ -97,4 +97,8 @@ public class Boat {
public Color getColor() {
return color;
}
public double getSpeedInKnots(){
return Math.round((this.velocity * 1.94384) * 100d) / 100d;
}
}
+1 -1
View File
@@ -16,7 +16,7 @@ public class Race {
private long startTime = 0;
private double timeScale = 1;
private boolean raceFinished = false; // Race is finished
private int raceTime = -10; // Current time in the race
private int raceTime = -2; // Current time in the race
/**
* Race class containing the boats and legs in the race