Remove start button from StartController.

#story[778]
This commit is contained in:
David Wu
2017-05-04 12:41:14 +12:00
parent 09483fff2c
commit b60b4b257f
4 changed files with 17 additions and 8 deletions
@@ -43,7 +43,7 @@ public class StartController extends Controller implements Observer {
@FXML private Label timer;
@FXML private int PRERACE_TIME = 10;
@FXML Button fifteenMinButton;
//@FXML Button fifteenMinButton;
private RaceClock raceClock;
@@ -56,12 +56,13 @@ public class StartController extends Controller implements Observer {
* Begins the race with a scale factor of 1
*/
public void startRaceNoScaling() {
startRace(1);
//startRace(1);
countdownTimer(1);
}
private void startRace(int raceScale){
fifteenMinButton.setDisable(true);
countdownTimer(raceScale);
//fifteenMinButton.setDisable(true);
//countdownTimer(raceScale);
}
@Override
@@ -107,11 +108,12 @@ public class StartController extends Controller implements Observer {
@Override
public void handle(long arg0) {
timeLeft = startTime - currentTime;
if (timeLeft <= 0) {
if (visualiserInput.getRaceStatus().getRaceStatus()==2) {
updateTime("Race is starting...");
stop();
parent.beginRace(visualiserInput);
startWrapper.setVisible(false);
start.setVisible(false);
} else {
updateTime(timerFormat.format(currentTime));
@@ -166,4 +168,5 @@ public class StartController extends Controller implements Observer {
e.printStackTrace();
}
}
}