fix rotational friction between btMultiBody and btRigidBody
This commit is contained in:
15
examples/pybullet/examples/rotationalFriction.py
Normal file
15
examples/pybullet/examples/rotationalFriction.py
Normal file
@@ -0,0 +1,15 @@
|
||||
import time
|
||||
import pybullet as p
|
||||
import pybullet_data as pd
|
||||
useMaximalCoordinatesA = True
|
||||
useMaximalCoordinatesB = True
|
||||
p.connect(p.GUI)
|
||||
p.setAdditionalSearchPath(pd.getDataPath())
|
||||
cube=p.loadURDF("cube_rotate.urdf",useMaximalCoordinates=useMaximalCoordinatesA)
|
||||
p.loadURDF("sphere2.urdf",[0,0,2],useMaximalCoordinates=useMaximalCoordinatesB)
|
||||
p.setGravity(0,0,-10)
|
||||
p.setJointMotorControl2(cube,0,p.VELOCITY_CONTROL,targetVelocity=1, force=100)
|
||||
while (1):
|
||||
p.stepSimulation()
|
||||
time.sleep(1./240.)
|
||||
|
||||
Reference in New Issue
Block a user