예제 #1
0
 public virtual void Deselect()
 {
     IsSelected = false;
     IsFocused  = false;
     MatPropBlock.SetColor(ColorTint, StartColor);
     Renderers.ForEach(renderer => { renderer.SetPropertyBlock(MatPropBlock); });
 }
예제 #2
0
 public virtual void TryHighlight(Color highlightColor)
 {
     if (!IsSelected)
     {
         MatPropBlock.SetColor(ColorTint, highlightColor);
         Renderers.ForEach(renderer => { renderer.SetPropertyBlock(MatPropBlock); });
     }
 }
예제 #3
0
 public virtual void Select(Color selectionColor)
 {
     Timing.KillCoroutines(CoroutineName);
     jiggleAnim.Animate(CoroutineName);
     SFXManager.Instance.Play(SFXType.PLEPlaceObject, transform.position);
     IsSelected = true;
     MatPropBlock.SetColor(ColorTint, selectionColor);
     Renderers.ForEach(renderer => { renderer.SetPropertyBlock(MatPropBlock); });
 }