diff --git a/Assets/Scenes/Levels/Quarry.unity b/Assets/Scenes/Levels/Quarry.unity index 75979824..19f790a9 100644 --- a/Assets/Scenes/Levels/Quarry.unity +++ b/Assets/Scenes/Levels/Quarry.unity @@ -452550,6 +452550,10 @@ PrefabInstance: propertyPath: m_Name value: QuarryAudio objectReference: {fileID: 0} + - target: {fileID: 7585931024614860467, guid: ead4e790fa3a1924ebd1586c93cd5479, type: 3} + propertyPath: m_PlayOnAwake + value: 0 + objectReference: {fileID: 0} m_RemovedComponents: [] m_RemovedGameObjects: [] m_AddedGameObjects: [] diff --git a/Assets/Sound/Quarry/QuarryAudio.prefab b/Assets/Sound/Quarry/QuarryAudio.prefab index 075c8d17..fee8e639 100644 --- a/Assets/Sound/Quarry/QuarryAudio.prefab +++ b/Assets/Sound/Quarry/QuarryAudio.prefab @@ -138,6 +138,8 @@ GameObject: serializedVersion: 6 m_Component: - component: {fileID: 2873907538289469479} + - component: {fileID: 8545106365577783398} + - component: {fileID: 7585931024614860467} m_Layer: 0 m_Name: QuarryAudio m_TagString: Untagged @@ -162,6 +164,121 @@ Transform: - {fileID: 4121215864022656322} m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &8545106365577783398 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6199677512542707633} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: cb5c6632b7606ce43a0b2dbf11215dc8, type: 3} + m_Name: + m_EditorClassIdentifier: '::' + narratorAudioSource: {fileID: 9091997474527205907} + firstNarration: {fileID: 8300000, guid: d0a13dd948bacda48be267eec3e0b080, type: 3} + anneLiseExposition: {fileID: 0} + narrationFinished: + m_PersistentCalls: + m_Calls: [] +--- !u!82 &7585931024614860467 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6199677512542707633} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_Resource: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 --- !u!1 &6350035581257276269 GameObject: m_ObjectHideFlags: 0 @@ -173,7 +290,7 @@ GameObject: - component: {fileID: 2279651898552875333} - component: {fileID: 9091997474527205907} m_Layer: 0 - m_Name: Narrator + m_Name: Narrator1 m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -205,8 +322,8 @@ AudioSource: serializedVersion: 4 OutputAudioMixerGroup: {fileID: 3533147658878909314, guid: 727a7e4b6df4b0d47897f7d8ee7fa323, type: 2} m_audioClip: {fileID: 0} - m_Resource: {fileID: 8300000, guid: d0a13dd948bacda48be267eec3e0b080, type: 3} - m_PlayOnAwake: 1 + m_Resource: {fileID: 0} + m_PlayOnAwake: 0 m_Volume: 1 m_Pitch: 1 Loop: 0 diff --git a/Assets/Sound/Quarry/Scripts.meta b/Assets/Sound/Quarry/Scripts.meta new file mode 100644 index 00000000..545e5b96 --- /dev/null +++ b/Assets/Sound/Quarry/Scripts.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 423ebef95a1a80540a39e097c4a2c206 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs b/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs new file mode 100644 index 00000000..de962f5a --- /dev/null +++ b/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs @@ -0,0 +1,15 @@ +using UnityEngine; + +public class AnneLiseMain : MonoBehaviour +{ + // Start is called once before the first execution of Update after the MonoBehaviour is created + void Start() + { + + } + + void PlayIntroVO() + { + + } +} diff --git a/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs.meta b/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs.meta new file mode 100644 index 00000000..1307ac9c --- /dev/null +++ b/Assets/Sound/Quarry/Scripts/AnneLiseMain.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: f8fad2d7a81d63b45aad87edfd322669 \ No newline at end of file diff --git a/Assets/Sound/Quarry/Scripts/NarratorVO.cs b/Assets/Sound/Quarry/Scripts/NarratorVO.cs new file mode 100644 index 00000000..b6d273e0 --- /dev/null +++ b/Assets/Sound/Quarry/Scripts/NarratorVO.cs @@ -0,0 +1,35 @@ +using UnityEngine; +using UnityEngine.Audio; +using AudioSourceEvents; +using System; +using UnityEngine.Events; + +public class NarratorVO : AudioSourceObserver +{ + public AudioSource narratorAudioSource; + public AudioResource firstNarration; + public UnityEvent narrationFinished; + + private IAudioEventSource _eventSource; + + // Start is called once before the first execution of Update after the MonoBehaviour is created + void Start() + { + PlayNarrationAudio(); + } + + void PlayNarrationAudio() + { + _eventSource = narratorAudioSource.RequestEventHandlers(); + _eventSource.AudioStopped += NarrationFinished; + + narratorAudioSource.resource = firstNarration; + narratorAudioSource.Play(); + } + + private void NarrationFinished(object sender, EventArgs e) + { + narrationFinished.Invoke(); + } + +} diff --git a/Assets/Sound/Quarry/Scripts/NarratorVO.cs.meta b/Assets/Sound/Quarry/Scripts/NarratorVO.cs.meta new file mode 100644 index 00000000..ea368058 --- /dev/null +++ b/Assets/Sound/Quarry/Scripts/NarratorVO.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: cb5c6632b7606ce43a0b2dbf11215dc8 \ No newline at end of file diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav new file mode 100644 index 00000000..fa3c00be Binary files /dev/null and b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav differ diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav.meta b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav.meta new file mode 100644 index 00000000..47941c79 --- /dev/null +++ b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro1.wav.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: f189b8a044a8ae94fb38d99dbfc7deed +AudioImporter: + externalObjects: {} + serializedVersion: 8 + defaultSettings: + serializedVersion: 2 + loadType: 0 + sampleRateSetting: 0 + sampleRateOverride: 44100 + compressionFormat: 1 + quality: 1 + conversionMode: 0 + preloadAudioData: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + loadInBackground: 0 + ambisonic: 0 + 3D: 1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav new file mode 100644 index 00000000..3022ace5 Binary files /dev/null and b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav differ diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav.meta b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav.meta new file mode 100644 index 00000000..598fd779 --- /dev/null +++ b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro2.wav.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 195905675bf639f458a88f7567a3adc1 +AudioImporter: + externalObjects: {} + serializedVersion: 8 + defaultSettings: + serializedVersion: 2 + loadType: 0 + sampleRateSetting: 0 + sampleRateOverride: 44100 + compressionFormat: 1 + quality: 1 + conversionMode: 0 + preloadAudioData: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + loadInBackground: 0 + ambisonic: 0 + 3D: 1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav new file mode 100644 index 00000000..a91dc281 Binary files /dev/null and b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav differ diff --git a/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav.meta b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav.meta new file mode 100644 index 00000000..8f3836fe --- /dev/null +++ b/Assets/Sound/Quarry/Voices/AnneLise/Annelise_intro3.wav.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 3f542c523460c5148a53ca2d5476a545 +AudioImporter: + externalObjects: {} + serializedVersion: 8 + defaultSettings: + serializedVersion: 2 + loadType: 0 + sampleRateSetting: 0 + sampleRateOverride: 44100 + compressionFormat: 1 + quality: 1 + conversionMode: 0 + preloadAudioData: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + loadInBackground: 0 + ambisonic: 0 + 3D: 1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Packages/manifest.json b/Packages/manifest.json index aa1d97f2..d802b594 100644 --- a/Packages/manifest.json +++ b/Packages/manifest.json @@ -1,5 +1,6 @@ { "dependencies": { + "com.moolt.packages.net": "git+https://github.com/Moolt/UnityAudioSourceEvents?path=Packages/AudioSourceEvents", "com.unity.2d.sprite": "1.0.0", "com.unity.2d.spriteshape": "12.0.1", "com.unity.addressables": "2.7.3", diff --git a/Packages/packages-lock.json b/Packages/packages-lock.json index 0de01da8..af7ec4c0 100644 --- a/Packages/packages-lock.json +++ b/Packages/packages-lock.json @@ -1,5 +1,12 @@ { "dependencies": { + "com.moolt.packages.net": { + "version": "git+https://github.com/Moolt/UnityAudioSourceEvents?path=Packages/AudioSourceEvents", + "depth": 0, + "source": "git", + "dependencies": {}, + "hash": "813bd3cb990a91d2964bdf1f6daca341c54cab80" + }, "com.unity.2d.animation": { "version": "12.0.2", "depth": 1,