void Awake() { if (instance == null) { instance = this; } }
private void Awake() { if (sfxInstance != null && sfxInstance != this) { Destroy(this.gameObject); return; } sfxInstance = this; DontDestroyOnLoad(this); }