void Awake() { if (instance == null) { instance = this; lineRenderers = new LineRenderer[0]; InitializeLineRenderers(1); } else { Destroy(this.gameObject); Debug.LogError("Destroyed duplicate instance of ShipPathVisualizer"); } }
void Awake() { if (instance == null){ instance = this; lineRenderers = new LineRenderer[0]; InitializeLineRenderers(1); } else{ Destroy(this.gameObject); Debug.LogError("Destroyed duplicate instance of ShipPathVisualizer"); } }