Update Cinematic Manager, Hud Manager, fix log verbosity issue, update PauseMenu
This commit is contained in:
@@ -53,18 +53,34 @@ public class AudioManager : ManagedBehaviour, IPausable
|
||||
|
||||
protected override void OnManagedAwake()
|
||||
{
|
||||
// Auto-registration with GameManager handled by ManagedBehaviour
|
||||
}
|
||||
// Initialize lists if they were not set in inspector
|
||||
criticalVOSources = criticalVOSources ?? new List<AppleAudioSource>();
|
||||
VOSources = VOSources ?? new List<AppleAudioSource>();
|
||||
musicSources = musicSources ?? new List<AppleAudioSource>();
|
||||
ambienceSources = ambienceSources ?? new List<AppleAudioSource>();
|
||||
SFXSources = SFXSources ?? new List<AppleAudioSource>();
|
||||
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void Start()
|
||||
{
|
||||
_player = QuickAccess.Instance.PlayerGameObject;
|
||||
_audioListener = QuickAccess.Instance.MainCamera.GetComponent<AudioListener>();
|
||||
// Perform singleton-dependent initialization here
|
||||
if (QuickAccess.Instance != null)
|
||||
{
|
||||
_player = QuickAccess.Instance.PlayerGameObject;
|
||||
if (QuickAccess.Instance.MainCamera != null)
|
||||
{
|
||||
_audioListener = QuickAccess.Instance.MainCamera.GetComponent<AudioListener>();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.LogWarning("[AudioManager] QuickAccess.Instance is null during OnManagedAwake. Some audio references may remain unset.");
|
||||
}
|
||||
|
||||
// Diagnostic
|
||||
foreach (AppleAudioSource _audioSource in criticalVOSources)
|
||||
{
|
||||
Debug.Log("Found source: " + _audioSource.name);
|
||||
}
|
||||
|
||||
Debug.Log("[AudioManager] OnManagedAwake completed");
|
||||
}
|
||||
|
||||
public void SetAudioPauseBehavior(PauseBehavior newPauseBehavior)
|
||||
|
||||
Reference in New Issue
Block a user