Esempio n. 1
0
 void OnTriggerEnter(Collider c)
 {
     if (c.GetComponent <Holdable>() != null)
     {
         holdable = c.GetComponent <Holdable>();
         holdable.SetHighlightColor();
     }
     else if (c.GetComponent <Button>() != null)
     {
         button = c.GetComponent <Button>();
     }
     else if (c.transform.parent.parent.GetComponent <SliderScript>() != null)
     {
         slider = c.transform.parent.parent.GetComponent <SliderScript>();
     }
 }