Speed scale is 2, rather than 10.

Server simulates frames every 16ms rather than 50ms.
main
fjc40 8 years ago
parent 5c58ca11ff
commit 191f249bfb

@ -91,7 +91,7 @@ public class RaceLogic implements RunnableWithFramePeriod, Observer {
server.parseSnapshot();
waitForFramePeriod(previousFrameTime, currentTime, 50);
waitForFramePeriod(previousFrameTime, currentTime, 16);
previousFrameTime = currentTime;
}
}
@ -128,7 +128,7 @@ public class RaceLogic implements RunnableWithFramePeriod, Observer {
race.setBoatsStatusToRacing();
}
waitForFramePeriod(previousFrameTime, currentTime, 50);
waitForFramePeriod(previousFrameTime, currentTime, 16);
previousFrameTime = currentTime;
}
@ -206,7 +206,7 @@ public class RaceLogic implements RunnableWithFramePeriod, Observer {
previousFrameTime = currentTime;
}
waitForFramePeriod(previousFrameTime, currentTime, 50);
waitForFramePeriod(previousFrameTime, currentTime, 16);
previousFrameTime = currentTime;
}
}

@ -28,7 +28,7 @@ public class Constants {
* Frame periods are multiplied by this to get the amount of time a single frame represents.
* E.g., frame period = 20ms, scale = 5, frame represents 20 * 5 = 100ms, and so boats are simulated for 100ms, even though only 20ms actually occurred.
*/
public static final int RaceTimeScale = 10;
public static final int RaceTimeScale = 2;
/**
* The race pre-start time, in milliseconds. 30 seconds.

Loading…
Cancel
Save