diff --git a/src/SimulationRunner.cc b/src/SimulationRunner.cc index 250d0f2fb2..06aaa66670 100644 --- a/src/SimulationRunner.cc +++ b/src/SimulationRunner.cc @@ -661,7 +661,13 @@ bool SimulationRunner::Run(const uint64_t _iterations) if (!this->statsPub.Valid()) { transport::AdvertiseMessageOptions advertOpts; - advertOpts.SetMsgsPerSec(5); + // publish 10 world statistics msgs/second. A smaller number isn't used + // because the GUI listens to these msgs to receive confirmation that + // pause/play GUI requests have been processed by the server, so we want to + // make sure that GUI requests are acknowledged quickly (see + // https://github.com/ignitionrobotics/ign-gui/pull/306 and + // https://github.com/ignitionrobotics/ign-gazebo/pull/1163) + advertOpts.SetMsgsPerSec(10); this->statsPub = this->node->Advertise( "stats", advertOpts); }