title: How do I save all generated Lines on the screen
body: <p>I have two moving Objects and want to connect them with multiple lines. The Lines will be drawn, but disappearing when a new one is created.</p>
  
  <p>How can I save all generated lines ?</p>
  
  <pre><code>void CreateLine()
  {
      line = new GameObject("Line" + currLines).AddComponent&lt;LineRenderer&gt;();
      line = GetComponent&lt;LineRenderer&gt;();
      line.SetPosition(0, Pos1);
      line.SetPosition(1, Pos2);
      line.startColor = Color.white;
      line.endColor = Color.white;
      line.startWidth = 5;
      line.endWidth = 5;
      line.positionCount = 2;
      line.sortingOrder = 2;
      line.useWorldSpace = true;
      currLines++;
  }
  
  void Start()
  {
      Pos1 = GameObject.FindGameObjectWithTag("Pos1");
      Pos2 = GameObject.FindGameObjectWithTag("Pos2");
  
      InvokeRepeating("CreateLine", 0, 0.05f);
  }
  </code></pre>