Collision
Complete API reference for Collision, including constructors, attributes, virtual attributes, and methods.
Package: JAVARuntime
Category: Physics
Component: no
public class Collision
Constructors
| Signature | Description |
|---|---|
Collision(Collision) | Executes Collision and returns after the underlying engine call finishes. |
Collision() | Executes Collision and returns after the underlying engine call finishes. |
Attributes
| Name | Type | Description |
|---|---|---|
instance | Collision | Represents the instance value stored on this instance. Read or assign to update the property. |
Virtual Attributes
| Name | Type | Access | Description |
|---|---|---|---|
collider | Collider | get/set | Returns the collider associated with this collision. |
colliderObject | SpatialObject | get/set | Returns the object associated with the Collider in this collision. |
contactCount | int | get | Returns the number of contact points in the collision. |
contactPoint | Vector3 | get/set | Returns the contact position of the first contact point (deprecated, get a Contact using contactAt() or getContactList() and call getContactPoint() on it). |
distance | float | get/set | Returns the penetration distance at the first contact point (deprecated, get a Contact using contactAt() or getContactList() and call getDistance() on it). |
impulse | float | get/set | Returns the impulse magnitude at the first contact point (deprecated, get a Contact using contactAt() or getContactList() and call getImpulse() on it). |
normal | Vector3 | get/set | Returns the normal vector of the first contact point (deprecated, get a Contact using contactAt() or getContactList() and call getNormal() on it). |
object | SpatialObject | get/set | Returns the other object involved in the collision. |
physicsComponent | PhysicsComponent | get/set | Returns the physics of the other object involved in the collision. |
Methods
| Signature | Returns | Description |
|---|---|---|
contactCount() | int | Returns the number of contact points in the collision. |
contactAt(int) | Contact | Returns the contact at the specified index. |
getContactList() | List<Contact> | Returns the list of contact points in the collision. |