Package com.github.stephengold.joltjni
Class VehicleCollisionTesterRay
java.lang.Object
com.github.stephengold.joltjni.JoltPhysicsObject
com.github.stephengold.joltjni.NonCopyable
com.github.stephengold.joltjni.VehicleCollisionTester
com.github.stephengold.joltjni.VehicleCollisionTesterRay
- All Implemented Interfaces:
ConstJoltPhysicsObject
,ConstVehicleCollisionTester
,RefTarget
,AutoCloseable
,Comparable<JoltPhysicsObject>
A
VehicleCollisionTester
that uses ray casts.-
Constructor Summary
ConstructorsConstructorDescriptionVehicleCollisionTesterRay
(int objectLayer) Instantiate a tester for the specified layer.VehicleCollisionTesterRay
(int objectLayer, Vec3Arg up) Instantiate a tester with the specified properties.VehicleCollisionTesterRay
(int objectLayer, Vec3Arg up, float maxSlopeAngle) Instantiate a tester with the specified properties. -
Method Summary
Modifier and TypeMethodDescriptiontoRef()
Create a counted reference to the nativeVehicleCollisionTesterRay
.Methods inherited from class com.github.stephengold.joltjni.VehicleCollisionTester
getObjectLayer, getRefCount, setEmbedded, setObjectLayer
Methods inherited from class com.github.stephengold.joltjni.JoltPhysicsObject
close, compareTo, equals, getContainingObject, hasAssignedNativeObject, hashCode, isCleanerStarted, ownsNativeObject, setVirtualAddress, setVirtualAddress, startCleaner, targetVa, toString, va
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface com.github.stephengold.joltjni.readonly.ConstJoltPhysicsObject
close, hasAssignedNativeObject, ownsNativeObject, targetVa
-
Constructor Details
-
VehicleCollisionTesterRay
public VehicleCollisionTesterRay(int objectLayer) Instantiate a tester for the specified layer.- Parameters:
objectLayer
- the index of the desired object layer for collisions (≥0)
-
VehicleCollisionTesterRay
Instantiate a tester with the specified properties.- Parameters:
objectLayer
- the index of the desired object layer for collisions (≥0)up
- the "up" direction (in system coordinates, not null, unaffected, default=(0,1,0))
-
VehicleCollisionTesterRay
Instantiate a tester with the specified properties.- Parameters:
objectLayer
- the index of the desired object layer for collisionsup
- the "up" direction (in system coordinates, not null, unaffected, default=(0,1,0))maxSlopeAngle
- the maximum angle to consider for colliding wheels (in radians, default=4*Pi/9)
-
-
Method Details
-
toRef
Create a counted reference to the nativeVehicleCollisionTesterRay
.- Specified by:
toRef
in interfaceRefTarget
- Overrides:
toRef
in classVehicleCollisionTester
- Returns:
- a new JVM object with a new native object assigned
-