mirror of
https://github.com/Farama-Foundation/Gymnasium.git
synced 2025-08-21 06:20:15 +00:00
if viewer is None then no need to close it.
This commit is contained in:
@@ -56,6 +56,7 @@ class MujocoEnv(gym.Env):
|
||||
|
||||
def _render(self, mode='human', close=False):
|
||||
if close:
|
||||
if self.viewer is not None:
|
||||
self._get_viewer().finish()
|
||||
return
|
||||
|
||||
|
Reference in New Issue
Block a user