From 66951ac102fb737a55c77cf21ab0a2bd38b3004c Mon Sep 17 00:00:00 2001 From: Erwin Coumans Date: Tue, 19 Nov 2019 19:35:28 -0800 Subject: [PATCH] fix Mac version of deformable_anchor.py --- examples/pybullet/examples/deformable_anchor.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/pybullet/examples/deformable_anchor.py b/examples/pybullet/examples/deformable_anchor.py index d55a1bc79..135a55c71 100644 --- a/examples/pybullet/examples/deformable_anchor.py +++ b/examples/pybullet/examples/deformable_anchor.py @@ -4,8 +4,8 @@ from time import sleep physicsClient = p.connect(p.GUI) p.resetSimulation(p.RESET_USE_DEFORMABLE_WORLD) - -p.setGravity(0, 0, -10) +gravZ=-10 +p.setGravity(0, 0, gravZ) planeOrn = [0,0,0,1]#p.getQuaternionFromEuler([0.3,0,0]) planeId = p.loadURDF("plane.urdf", [0,0,-2],planeOrn) @@ -24,6 +24,6 @@ p.setRealTimeSimulation(1) while p.isConnected(): - p.getNumBodies() + p.setGravity(0,0,gravZ) sleep(1./240.) - \ No newline at end of file +