TackGybeCommand now smooths the rotation of the boat. #story[1196]

This commit is contained in:
Joseph Gardner
2017-09-06 15:19:30 +12:00
parent f4cb1a3ac4
commit 00cedf4d4d
3 changed files with 35 additions and 14 deletions
@@ -145,9 +145,13 @@ public class RaceLogic implements RunnableWithFramePeriod, Observer {
//Get the current time.
long currentTime = System.currentTimeMillis();
//Execute commands from clients.
// Execute commands from clients.
commands.execute();
// Notify Observers
race.setChanged();
race.notifyObservers();
//Update race time.
race.updateRaceTime(currentTime);
@@ -185,10 +189,6 @@ public class RaceLogic implements RunnableWithFramePeriod, Observer {
previousFrameTime = currentTime;
}
// Notify Observers
race.setChanged();
race.notifyObservers();
waitForFramePeriod(previousFrameTime, currentTime, 50);
previousFrameTime = currentTime;
}