Example #1
0
 void OnTriggerEnter(Collider c)
 {
     if (!triggered && c.gameObject.name == "Player")
     {
         triggered = true;
         light.activate();
     }
 }
Example #2
0
 void OnTriggerEnter(Collider c)
 {
     if (!triggeredBall && c.gameObject.name == "Player")
     {
         triggeredBall = true;
         deathBall.rigidbody.useGravity = true;
         lightActivator.activate();
     }
 }