Size DOES matter: Trigger collider 'volume'

In this project, not so much. For future projects however, it does. This is a bit of an advanced topic for this course I think, but someone might find it interesting and save their hair in the future. I have 2 examples of this for those interested.

I have published my own 3d Action RPG game and ran into a collision detection issue that was a result of velocity and/or animations that did cause the detection to be missed. In my project, the positioning of a sword, which had a trigger collider attached, would occasionally not register a hit on a target because the animation moved too quickly, and the collider never (mathematically) intersected the target collider. It was a hard bug to find because the target was small and the animation movement is deceiving.

Another example that I have encountered was in an FPS project I worked on, however any project that has fast moving projectiles such as bullets or spells could encounter this. The velocity of an object such as a bullet can occasionally cause it to miss it’s target. For example, on one frame, the bullet exists right in front of a target object, not colliding with it’s trigger. On the next frame, because of the bullets “velocity” it is positioned behind the target object, also not colliding with the trigger.

You can read more info about this issue here: http://joostdevblog.blogspot.com/2010/10/

Here is an image to help illustrate this point:
CollisionDetection Skipping

For this course this topic is important. One easy example of this is the blockbreaker game. If you set bounce to >1, the momentum gains from keeping the ball in place makes the ball fly out of the collision walls, or fall straight down into the lose zone.

1 Like

Exactly. I’ve recently encountered this as well while working through that project. A perfect example of the point I was attempting to make in this post. Thanks!

1 Like

Yep. This is why it’s best to put constraints on momentum, velocity and other physics factors to minimise these issues. Playtesting and troubleshooting are also a must.

Privacy & Terms