using QuickOutline; using UnityEngine; [RequireComponent(typeof(Outline))] public class Target : MonoBehaviour { Outline outline; public void Init() { outline = GetComponent(); gameObject.layer = LayerMask.NameToLayer("Target"); Hide(); } public void Show() { gameObject.SetActive(true); UnFocus(); } public void Hide() { gameObject.SetActive(false); } public void UnFocus() { outline.OutlineColor = new Color(0,1,0); } public void Focus() { outline.OutlineColor = new Color(1,1,0); } public void Execute() { //todo Debug.Log(name+" Success"); } }