Rename detach_default and detach_body to delete in the mjSpec bindings.
PiperOrigin-RevId: 773674361 Change-Id: I3977060e19e9ff0afc65ad91693c017958576b78
This commit is contained in:
committed by
Copybara-Service
parent
e23b39fbfa
commit
a2acd2d4ed
+4
-4
@@ -1827,7 +1827,7 @@
|
||||
"\n",
|
||||
"# Remove all bodies in the list from the spec\n",
|
||||
"for body in delete_list:\n",
|
||||
" spec.detach_body(body)\n",
|
||||
" spec.delete(body)\n",
|
||||
"\n",
|
||||
"# # Add another humanoid\n",
|
||||
"spec_humanoid = mj.MjSpec.from_file(humanoid_file)\n",
|
||||
@@ -1900,8 +1900,8 @@
|
||||
"shoulder_right = torso.add_frame(pos=arm_right.pos)\n",
|
||||
"\n",
|
||||
"# Remove the arms\n",
|
||||
"spec.detach_body(arm_left)\n",
|
||||
"spec.detach_body(arm_right)\n",
|
||||
"spec.delete(arm_left)\n",
|
||||
"spec.delete(arm_right)\n",
|
||||
"\n",
|
||||
"# Add new legs\n",
|
||||
"shoulder_left.attach_body(leg_left, 'shoulder', 'left')\n",
|
||||
@@ -1942,7 +1942,7 @@
|
||||
"arm_right = spec.body('upper_arm_right')\n",
|
||||
"torso = spec.body('torso')\n",
|
||||
"shoulder_right = torso.add_frame(pos=arm_right.pos, quat=[0, 0.8509035, 0, 0.525322])\n",
|
||||
"spec.detach_body(arm_right)\n",
|
||||
"spec.delete(arm_right)\n",
|
||||
"\n",
|
||||
"# Attach Franka arm to humanoid\n",
|
||||
"franka_arm = franka.body('fr3_link2')\n",
|
||||
|
||||
Reference in New Issue
Block a user