mujoco_step
Advance a MuJoCo simulation by multiple physics steps in one call, optionally set persistent actuator controls, and retrieve the resulting state JSON.
Instructions
Advance the simulation. Optionally set actuator controls first; ctrl persists across later steps.
Returns the post-step state JSON: {session_id, time, steps_taken, qpos, qvel, ctrl, sensors, ...}
filtered by `include`. Batch steps in one call (e.g. nsteps=500 for 1s at timestep 0.002)
instead of many single-step calls. Errors and suggests mujoco_reset if the state diverges.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ctrl | No | Actuator controls: full vector in actuator order, or {actuator_name: value} for a subset. Persists on the session until changed. | |
| nsteps | No | Physics steps to advance; simulated time = nsteps * timestep | |
| include | No | State blocks to return, any of: qpos, qvel, ctrl, sensors, sensors_raw, bodies, contacts (default: qpos, qvel, ctrl, sensors) | |
| precision | No | Decimal places for returned floats | |
| session_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |