private void AllEnemiesInTheLevelDestroyed() { _currentLevel++; var newAsteroidsCount = _currentLevel + _startingAsteroids; OnLevelCleared?.Invoke(_currentLevel); LoadNewLevel(_currentLevel, newAsteroidsCount); }
/** * Destroy all children in the scene. */ public void Clear() { /// @todo don't reference pb_Selection in pb_Scene. pb_Selection.Clear(); foreach (Transform t in transform) { pb_ObjectUtility.Destroy(t.gameObject); } OnLevelCleared?.Invoke(); }
public void LevelCleared() { OnLevelCleared?.Invoke(); }