File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -9,9 +9,14 @@ title: Simulated Time
9
9
10
10
In the simulated environment, time advances only at the pace that the simulator
11
11
is run and in cooperation with the controller code (such as the code controlling
12
- your robot). As a result, using the ` time ` method to know how long your robot has been
13
- running for or ` sleep ` method to wait for some duration is the most reliable way of
14
- implementing precise movements in your robot
12
+ your robot). As a result, using ` time.time ` to know how long your robot has been
13
+ running for or ` time.sleep ` to wait for some duration will have unpredictable
14
+ results, especially when run on a computer other than the one you are developing
15
+ on (such as during the competition).
16
+
17
+ Instead your code should explicitly signal to the simulator when it is ready for
18
+ time to advance and should query for the current time from the simulator. This
19
+ can be done by using the methods detailed below.
15
20
16
21
<div class =" info " >
17
22
If you find that the simulator freezes then this indicates that your code is
You can’t perform that action at this time.
0 commit comments