Flash >> Collision Detection Kit >> Drawing Example

Draw! You can make changes on the fly without missing a beat.

In this example, an empty movie clip sits on the stage, set to detect collisions with the balls falling from above. Clicking and dragging on the stage will draw lines into that movie clip. Because the clip is already set to detect collisions, there's no code to add! Collisions are detected even as your display objects change over time. If you wish to start over at any time, click the "Clear Canvas" button.

Using the Collision Detection Kit requires few lines of code, and next to no maintenance. For more information, please reference the documentation.

This example shows how you can exclude alpha values from collision detections. See how the Collision Detection Kit can exclude colors from collision checking. See how you can detect collisions on the fly. Draw on the stage to see how easy it is to work with organic shapes. The Collision Detection Kit plays well with TextField objects, as this example demonstrates. The kit even works with video. Watch how easy it is in this example. This demonstration shows off an important part of the Collision Detection Kit - returning the angle of collision. The kit accounts for local transforms like scale and rotation, as demonstrated in this example.