Ensure noise is injected when the simulation is paused and a single step is manually requested
PiperOrigin-RevId: 807688008 Change-Id: I8de9706c633565d6d6944b58d34de9da1037a837
This commit is contained in:
committed by
Copybara-Service
parent
eacad44a1a
commit
afbefc38a6
@@ -380,6 +380,9 @@ void PhysicsLoop(mj::Simulate& sim) {
|
|||||||
syncSim = d->time;
|
syncSim = d->time;
|
||||||
sim.speed_changed = false;
|
sim.speed_changed = false;
|
||||||
|
|
||||||
|
// inject noise
|
||||||
|
sim.InjectNoise();
|
||||||
|
|
||||||
// run single step, let next iteration deal with timing
|
// run single step, let next iteration deal with timing
|
||||||
mj_step(m, d);
|
mj_step(m, d);
|
||||||
const char* message = Diverged(m->opt.disableflags, d);
|
const char* message = Diverged(m->opt.disableflags, d);
|
||||||
|
|||||||
Reference in New Issue
Block a user