title: Access component from another script
body: <p>Im using unity and I have Im trying to access a script called <code>Outline</code> on my parent object. I need to disable and enable the script <code>Outline</code> from another script called <code>Destroyable</code>. I know theres a ton of tutorials out there and other questions asked but it always seems to not be able to find it. </p>
  
  <pre class="lang-c# prettyprint-override"><code>using System.Collections;
  using System.Collections.Generic;
  using UnityEngine;
  
  public class Destroyable : MonoBehaviour
  {
      Outline myScript;
      private void OnMouseDown()
      {
          Destroy(gameObject);
      }
  
      // Start is called before the first frame update
      private void Start()
      {
          myScript = gameObject.GetComponent&lt;Outline&gt;();
      }
  
      // Update is called once per frame
      void Update()
      {
  
      }
  }
  </code></pre>