示例#1
0
 private void OnCollisionEnter(Collision collision)
 {
     if (collision.gameObject.name == "Bagel") //hacky code, detect bagel and enable "bagel halves"
     {
         bagelscript.SplitBagel();
     }
 }
 void SplitBagel()
 {
     bagelscript.SplitBagel();
 }