private void Start() { Canvas canvas = GetComponentInChildren <Canvas>(); canvas.worldCamera = Camera.current; _manager = FindObjectOfType <WaveSpawner>(); }
private void Start() { if (_instance == null) { _instance = this; } if (waves.Length > 0) { foreach (Wave wave in waves) { wave.wordSpawner.Load(); } } enemyWaveUI = FindObjectOfType <EnemyWaveUI>(); enemyWaveUI.SetNumberOfWave(waves.Length); StartCoroutine(DoSpawnLoop()); }