Book Image

Building Levels in Unity

By : Volodymyr Gerasimov
Book Image

Building Levels in Unity

By: Volodymyr Gerasimov

Overview of this book

Table of Contents (17 chapters)
Building Levels in Unity
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
4
Dealing with Basic Animations
Index

Collider


Collider is a shell that is used to register physical interactions between objects; however, this will not prevent objects from moving into each other. Colliders are there to register collision, not to prevent it. To add a collider to an object, we need to add yet another component called Box Collider under Physics | Box Collider. The purpose of the collider is to register the collision between itself and objects controlled by physics and essentially to prevent your character from walking through walls and falling through the floor. Collider can be transformed manually by clicking Edit Collider button and dragging its boundaries

You might have noticed that there are a lot more colliders, but the Box Collider is the most commonly used one because of its simple geometry. Based on object topology and collision precision requirements, you might have to use multiple colliders by adding more collider components. The best results can be achieved by using Mesh Collider, which will copy...