Skip to content

On Collision Enter ​

Physics & collisionsDetailedOnCollisionEnter

A non-player collider hits this one (needs a Rigidbody on one of them).

Happens when this object's collider starts touching another collider. Both must have Is Trigger off, and at least one needs a Rigidbody with Is Kinematic off. So nothing happens between a kinematic object and a floor without a Rigidbody.

What hit it is a Collision: data about the contact points, the impact speed and so on.

The trigger can sit on either side. When a box with a Rigidbody falls onto the floor, it fires on a trigger on the floor and on a trigger on the box.

To notice players hitting it, use On Player Collision Enter.

Official docs: OnCollisionEnter (Unity), Interaction between collider types (Unity)

Event values

Values this event has; action settings can use them as targets or values.

NameType
What hit itCollision

On a card

WhenOn Collision Enter⋯
What to do
+ Add what to do

In Udon

In UdonSharp, this is the method:

void OnCollisionEnter(Collision other)

In the same category