public class RigidBodyMotionState
extends com.bulletphysics.linearmath.MotionState
Constructor and Description |
---|
RigidBodyMotionState() |
Modifier and Type | Method and Description |
---|---|
boolean |
applyTransform(Spatial spatial)
applies the current transform to the given jme Node if the location has been updated on the physics side
|
Vector3f |
getWorldLocation() |
Matrix3f |
getWorldRotation() |
Quaternion |
getWorldRotationQuat() |
com.bulletphysics.linearmath.Transform |
getWorldTransform(com.bulletphysics.linearmath.Transform t)
Called from Bullet when creating the rigid body.
|
boolean |
isApplyPhysicsLocal() |
void |
setApplyPhysicsLocal(boolean applyPhysicsLocal) |
void |
setVehicle(PhysicsVehicle vehicle) |
void |
setWorldTransform(com.bulletphysics.linearmath.Transform worldTrans)
Called from Bullet when the transform of the rigid body changes.
|
public com.bulletphysics.linearmath.Transform getWorldTransform(com.bulletphysics.linearmath.Transform t)
getWorldTransform
in class com.bulletphysics.linearmath.MotionState
t
- caller-provided storage for the Transformpublic void setWorldTransform(com.bulletphysics.linearmath.Transform worldTrans)
setWorldTransform
in class com.bulletphysics.linearmath.MotionState
worldTrans
- the new value (not null, unaffected)public boolean applyTransform(Spatial spatial)
spatial
- where to apply the physics transform (not null, modified)public Vector3f getWorldLocation()
public Matrix3f getWorldRotation()
public Quaternion getWorldRotationQuat()
public void setVehicle(PhysicsVehicle vehicle)
vehicle
- the vehicle to setpublic boolean isApplyPhysicsLocal()
public void setApplyPhysicsLocal(boolean applyPhysicsLocal)