Package com.github.stephengold.joltjni
Class RagdollRef
java.lang.Object
com.github.stephengold.joltjni.JoltPhysicsObject
com.github.stephengold.joltjni.template.Ref
com.github.stephengold.joltjni.RagdollRef
- All Implemented Interfaces:
ConstJoltPhysicsObject,AutoCloseable,Comparable<ConstJoltPhysicsObject>
A counted reference to a
Ragdoll.-
Method Summary
Modifier and TypeMethodDescriptionvoidaddToPhysicsSystem(EActivation activation) Add bodies and constraints to the physics system and optionally activate the bodies.voidDrive the ragdoll to the specified pose using motors.getPtr()Temporarily access the referencedRagdoll.voidRemove bodies and constraints from the physics system.voidsetPose(SkeletonPose pose) Alter the ragdoll's pose using the locking body interface.voidsetPose(SkeletonPose pose, boolean lockBodies) Alter the ragdoll's pose.toRef()Create a counted reference to the nativeRagdollRef.Methods inherited from class com.github.stephengold.joltjni.JoltPhysicsObject
close, compareTo, equals, hasAssignedNativeObject, hashCode, ownsNativeObject, setVirtualAddress, startCleaner, toString, va
-
Method Details
-
addToPhysicsSystem
Add bodies and constraints to the physics system and optionally activate the bodies.- Parameters:
activation- whether to activate bodies (not null)
-
driveToPoseUsingMotors
Drive the ragdoll to the specified pose using motors.- Parameters:
pose- the desired pose (not null, unaffected)
-
removeFromPhysicsSystem
public void removeFromPhysicsSystem()Remove bodies and constraints from the physics system. -
setPose
Alter the ragdoll's pose using the locking body interface.- Parameters:
pose- the desired pose (not null, unaffected)
-
setPose
Alter the ragdoll's pose.- Parameters:
pose- the desired pose (not null, unaffected)lockBodies- true→use the locking body interface, false→use the non-locking body interface
-
getPtr
Temporarily access the referencedRagdoll. -
toRef
Create a counted reference to the nativeRagdollRef.
-