Prime difference between colliders and triggers — Unity3D

Alberto Garcia
2 min readDec 13, 2022

--

The collision system fundamentally differs from triggers because of all the physics calculations occurring in real time about contact points and impact velocity. Only with colliders can things like bounciness occur.

Bouncy physic material for Sphere
Added physic material to Sphere Collider
Bouncing sphere

For this type of events, OnCollisionEnter is the required method to achieve effects like changing the material of an object after bouncing from a specific platform, activate a detonation system after certain impact force, or even setting the score every time the player jumps in a trampoline.

OnTriggerEnter events act like ghosts, having no impact on the physical reaction of objects. A laser-detection alarm system would be one of the best examples, as a pass-through detection. The triggers system simplifies calculations and works best along animations that react to the triggers. In the case of the 2D Space Shooter, having a player with a trigger collider simplifies the navigation behavior for the enemies and player, avoiding undesired spinning and turning.

--

--

Alberto Garcia
Alberto Garcia

No responses yet