Humanoid Control for Unity v4
|
Implements behaviour based on collisions.
The Collision Event Handler is a convenience component to act on collision events without programming. It is a specific implementation of an EventHandler.
The Collision Event Handler can be placed on GameObjects and Rigidbodies to catch collision events and execute functions when this happens.
The event type is as follows:
When the Target Method takes a GameObject as parameter, the Target method will receive the GameObject of the collider which is touching this collider.
When the Target Method takes a boolean parameter, a constant value can be used or the parameter can be set to From Event. When the parameter comes from the event, the boolean value is true when the collider is touching another collider and false when not.
When the Target Method takes a integer (Int32) parameter, a constant value can be used or the parameter can be set to From Event. When the parameter comes from the event, the integer value is 1 when the collider is touching another collider and 0 when not.
When the Target Method takes a float (Single) parameter, a constant value can be used or the parameter can be set to From Event. When the parameters comes from the event, the float value is 1.0 when the collider is touching another collider and 0.0 when not.
Inherits MonoBehaviour.
Public Attributes | |
GameObjectEventHandlers | collisionHandlers |
Protected Member Functions | |
virtual void | OnCollisionEnter (Collision collision) |
virtual void | OnCollisionExit (Collision collision) |
GameObjectEventHandlers Passer.CollisionEventHandler.collisionHandlers |