Gaming Guide > Placing a Target in an Imported Animation > Bounding Boxes and Collisions
Download Toon Boom DocumentationDownload Documentation

Bounding Boxes and Collisions

Extracting the bounding box information is useful when you want to make something collide with your character. When you put a 2D character into a 3D scene, you may want to use Physics to make the 2D character collide with the 3D plane. To use the following scripts, you will need to be using Unity 4.3 or higher.

In the Demo scene, open the DemoPhysics example to see collisions and bounding boxes in use. In this example, there’s a 3D plane and some 2D characters. The 2D characters have a collision defined with their bounding box, and they are also reacting to the physics of the scene to fall with gravity.

To enable a collision based on the bounding box of the character, simply select your imported character. In the Inspector, click on Add Component > Physics 2D > Box Collider 2D.

To enable the Physics on the character, go to Add Component > Physics 2D > Rigid Body 2D.

You can also use 3D physics on your imported files as well.

Now adjust the variables and see the results!