Beispiel #1
0
 def init(self):
     """Register with physics engine"""
     self.engine.physics_system.register_entity(self.entity, 0, bullet.btDefaultMotionState)
     xform = vector.transform_zero()
     self.entity.rigid_body.getMotionState().getWorldTransform(xform)
     self.position = vector.ogre_vector_from_transform(xform)
 def get_orientation(self):
     xform = vector.transform_zero()
     self.getWorldTransform(xform)
     return vector.ogre_quaternion_from_transform(xform)
 def set_orientation(self, o):
     xform = vector.transform_zero()
     self.getWorldTransform(xform)
     xform.setRotation(o)
 def position(self):
     xform = vector.transform_zero()
     self.getWorldTransform(xform)
     return vector.ogre_vector_from_transform(xform)