@@ -324,7 +324,7 @@ def on_prepare_visualization(self, event):
324324
325325 self .visualization_launcher .run ()
326326
327- if self .visualization_type in ["gazebo_rae" , "gzsim_rae" ]:
327+ if self .visualization_type in ["gazebo_rae" , "gzsim_rae" , "console" ]:
328328 self .gui_server = Server (2303 , self .update )
329329 self .gui_server .start ()
330330 elif self .visualization_type in ["bt_studio" , "bt_studio_gz" ]:
@@ -798,13 +798,13 @@ def on_resume(self, msg):
798798 def pause_sim (self ):
799799 if self .visualization_type in ["gzsim_rae" , "bt_studio_gz" ]:
800800 self .call_gzservice ("$(gz service -l | grep '^/world/\w*/control$')" ,"gz.msgs.WorldControl" ,"gz.msgs.Boolean" ,"3000" ,"pause: true" )
801- else :
801+ elif not self . visualization_type in [ "console" ] :
802802 self .call_service ("/pause_physics" , "std_srvs/srv/Empty" )
803803
804804 def unpause_sim (self ):
805805 if self .visualization_type in ["gzsim_rae" , "bt_studio_gz" ]:
806806 self .call_gzservice ("$(gz service -l | grep '^/world/\w*/control$')" ,"gz.msgs.WorldControl" ,"gz.msgs.Boolean" ,"3000" ,"pause: false" )
807- else :
807+ elif not self . visualization_type in [ "console" ] :
808808 self .call_service ("/unpause_physics" , "std_srvs/srv/Empty" )
809809
810810 def reset_sim (self ):
@@ -817,7 +817,7 @@ def reset_sim(self):
817817 self .call_gzservice ("$(gz service -l | grep '^/world/\w*/control$')" ,"gz.msgs.WorldControl" ,"gz.msgs.Boolean" ,"3000" ,"reset: {all: true}" )
818818 if self .is_ros_service_available ("/drone0/controller/_reset" ):
819819 self .call_service ("/drone0/controller/_reset" , "std_srvs/srv/Trigger" , "{}" )
820- else :
820+ elif not self . visualization_type in [ "console" ] :
821821 self .call_service ("/reset_world" , "std_srvs/srv/Empty" )
822822
823823 if self .robot_launcher :
0 commit comments