How to make OnTriggerEnter and OnTriggerExit functions more than once?


I have a code to switch a simply boolean on Enter and Exit, the thing it only work once.

Here is the two concerned function and the Boolean var.

var CanLaunch : boolean = false;

function OnTriggerEnter (ball) {
    CanLaunch = true;   

function OnTriggerExit (ball) {
    CanLaunch = false;  

On the first, enter it turn launch, and on the first exit it turn it false. But if the ball enter it again, it doesn't turn true again.

You have to add an Update function