void Awake() { InitMissingVars(); OnScenePaused.AddListener(OnScenePausedCallback); OnSceneResumed.AddListener(OnSceneResumedCallback); }
// Use this for initialization void Start() { InitMissingVars(); foreach (AudioSourceData audioSourceData in _audioSourceDataList) { // Debug.Log("AudioSource: " + audioSourceData.audioSource.clip.name); audioSourceData.audioSource.playOnAwake = false; } OnScenePaused.AddListener(OnScenePausedCallback); OnSceneResumed.AddListener(OnSceneResumedCallback); }