private void OnTriggerEnter2D(Collider2D collision) { if (pro.ans == 1) { if (collision.tag == "apple1") { pref.span = 3.5f; count1++; count2++; Qnum++; Gp.AddPoint(10); AppleDestroy(); } else if (collision.tag == "apple2" | collision.tag == "apple3") { Gp.AddPoint(-10); } } else if (pro.ans == 2) { if (collision.tag == "apple2") { pref.span = 3.5f; count1++; count2++; Qnum++; Gp.AddPoint(10); AppleDestroy(); } else if (collision.tag == "apple1" | collision.tag == "apple3") { Gp.AddPoint(-10); } } else if (pro.ans == 3) { if (collision.tag == "apple3") { pref.span = 3.5f; count1++; count2++; Qnum++; Gp.AddPoint(10); AppleDestroy(); } else if (collision.tag == "apple2" | collision.tag == "apple1") { Gp.AddPoint(-10); } } }