diff --git a/game/Assets/Prefabs/Environment/Spaceship.prefab b/game/Assets/Prefabs/Environment/Spaceship.prefab index 62eebd6..347bf62 100644 --- a/game/Assets/Prefabs/Environment/Spaceship.prefab +++ b/game/Assets/Prefabs/Environment/Spaceship.prefab @@ -9,6 +9,7 @@ GameObject: serializedVersion: 6 m_Component: - component: {fileID: 2149313816374391533} + - component: {fileID: 7084265813298723182} m_Layer: 0 m_Name: Spaceship m_TagString: Untagged @@ -27,12 +28,41 @@ Transform: m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: + - {fileID: 5674898676600736608} - {fileID: 1058519434748199728} - {fileID: 1415153319340462780} - {fileID: 9128309678831441048} m_Father: {fileID: 0} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &7084265813298723182 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95522237055879689} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0a5de09a27d949d4db67034f55c57e6b, type: 3} + m_Name: + m_EditorClassIdentifier: + _event: {fileID: 11400000, guid: f2cb97270d3bf9044b01dcac28561a9b, type: 2} + _response: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 4637354912713458198} + m_TargetAssemblyTypeName: UnityEngine.Behaviour, UnityEngine + m_MethodName: set_enabled + m_Mode: 6 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 1 + m_CallState: 2 --- !u!1 &1985622944643914252 GameObject: m_ObjectHideFlags: 0 @@ -62,7 +92,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 2149313816374391533} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!108 &6893796934365725642 Light: @@ -126,6 +156,50 @@ Light: m_UseViewFrustumForShadowCasterCull: 1 m_ShadowRadius: 0 m_ShadowAngle: 0 +--- !u!1 &2489985002885398785 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 5674898676600736608} + - component: {fileID: 4637354912713458198} + m_Layer: 0 + m_Name: Sounds + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &5674898676600736608 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2489985002885398785} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -0.539, y: 2.968, z: 2.793} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 2149313816374391533} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &4637354912713458198 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2489985002885398785} + m_Enabled: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 15c92baf151fbfa468ee0ba97f2197d9, type: 3} + m_Name: + m_EditorClassIdentifier: + _sfx: event:/VO/FuckedUpSpeech --- !u!1 &2599927563873625031 GameObject: m_ObjectHideFlags: 0 @@ -251,7 +325,7 @@ Transform: m_Children: - {fileID: 3270264341662508133} m_Father: {fileID: 2149313816374391533} - m_RootOrder: 2 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1001 &664884216927806683 PrefabInstance: @@ -262,7 +336,7 @@ PrefabInstance: m_Modifications: - target: {fileID: -8679921383154817045, guid: 78571f1c817068a448bf7da85e8ef9b3, type: 3} propertyPath: m_RootOrder - value: 0 + value: 1 objectReference: {fileID: 0} - target: {fileID: -8679921383154817045, guid: 78571f1c817068a448bf7da85e8ef9b3, type: 3} propertyPath: m_LocalScale.x diff --git a/game/Assets/Prefabs/Player.prefab b/game/Assets/Prefabs/Player.prefab index 79dad97..e01856c 100644 --- a/game/Assets/Prefabs/Player.prefab +++ b/game/Assets/Prefabs/Player.prefab @@ -174,6 +174,7 @@ MonoBehaviour: _dialogueSystem: {fileID: 11400000, guid: 56369c4e83cc59e44bf55cd16fafc4e8, type: 2} _freezeFirstUseDialogueKey: SD_FREEZE_0 _freezeVfx: {fileID: 0} + _jumpSfx: event:/Character/Jump _freezeSfx: event:/Character/Freeze _blinkSfx: event:/Character/Dash _boostSfx: event:/Character/Jump diff --git a/game/Assets/Scripts/Audio/LoopySound.cs b/game/Assets/Scripts/Audio/LoopySound.cs new file mode 100644 index 0000000..81431a7 --- /dev/null +++ b/game/Assets/Scripts/Audio/LoopySound.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using System.Diagnostics.Tracing; +using FMOD.Studio; +using FMODUnity; +using UnityEngine; +using STOP_MODE = FMOD.Studio.STOP_MODE; + +public class LoopySound : MonoBehaviour +{ + [SerializeField] + [EventRef] + private string _sfx; + + private EventInstance _sfxInstance; + + void Awake() + { + _sfxInstance = RuntimeManager.CreateInstance( _sfx ); + RuntimeManager.AttachInstanceToGameObject( _sfxInstance, transform, (Rigidbody)null ); + } + + private void OnEnable() + { + _sfxInstance.start(); + } + + private void OnDisable() + { + _sfxInstance.stop(STOP_MODE.IMMEDIATE); + } +} diff --git a/game/Assets/Scripts/Audio/LoopySound.cs.meta b/game/Assets/Scripts/Audio/LoopySound.cs.meta new file mode 100644 index 0000000..261f2ef --- /dev/null +++ b/game/Assets/Scripts/Audio/LoopySound.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 15c92baf151fbfa468ee0ba97f2197d9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/game/Assets/Scripts/Player/PlayerController.cs b/game/Assets/Scripts/Player/PlayerController.cs index e68ac16..fde9a1a 100644 --- a/game/Assets/Scripts/Player/PlayerController.cs +++ b/game/Assets/Scripts/Player/PlayerController.cs @@ -96,6 +96,11 @@ public class PlayerController : MonoBehaviour [SerializeField] private GameObject _freezeVfx; + [SerializeField] + [FMODUnity.EventRef] + private string _jumpSfx; + private EventInstance _jumpInstance; + [SerializeField] [FMODUnity.EventRef] private string _freezeSfx; @@ -127,6 +132,7 @@ public class PlayerController : MonoBehaviour { _freezeVfx.SetActive( false ); + _jumpInstance = RuntimeManager.CreateInstance( _jumpSfx ); _freezeInstance = RuntimeManager.CreateInstance( _freezeSfx ); _blinkInstance = RuntimeManager.CreateInstance( _blinkSfx ); _boostInstance = RuntimeManager.CreateInstance( _boostSfx ); @@ -134,7 +140,7 @@ public class PlayerController : MonoBehaviour private void PlayPlayerSFX( EventInstance instance ) { - instance.stop(STOP_MODE.IMMEDIATE); + instance.stop(STOP_MODE.ALLOWFADEOUT); instance.start(); RuntimeManager.AttachInstanceToGameObject( instance, transform, (Rigidbody)null ); } @@ -255,6 +261,8 @@ public class PlayerController : MonoBehaviour _jumpState = JumpState.Jump; _yVelocity = Mathf.Sqrt( 2f * _movementSettings.JumpHeight * _movementSettings.UpGravity ); + PlayPlayerSFX( _jumpInstance ); + // always make sure we can blink once per jump _powers.Blink.Reset(); } diff --git a/game/Assets/Scripts/Traps/ArrowWall.cs b/game/Assets/Scripts/Traps/ArrowWall.cs index b71da27..fde933d 100644 --- a/game/Assets/Scripts/Traps/ArrowWall.cs +++ b/game/Assets/Scripts/Traps/ArrowWall.cs @@ -35,7 +35,7 @@ public class ArrowWall : MonoBehaviour if (elapsed > _delay && objectTimeScale!=0) { // TODO: arrow whoosh noises - FMODUnity.RuntimeManager.PlayOneShot(_settings.ArrowWall.FMODEvent); + FMODUnity.RuntimeManager.PlayOneShot(_settings.ArrowWall.FMODEvent, transform.position); _particles.Play(); diff --git a/game/Assets/Scripts/Traps/FallawayFloor.cs b/game/Assets/Scripts/Traps/FallawayFloor.cs index 89c294f..6941bd3 100644 --- a/game/Assets/Scripts/Traps/FallawayFloor.cs +++ b/game/Assets/Scripts/Traps/FallawayFloor.cs @@ -87,7 +87,7 @@ public class FallawayFloor : MonoBehaviour // var shake = _graphics.transform.DOShakePosition( // fallAwayTime, // _settings.FallawayFloor.ShakeStrength); - FMODUnity.RuntimeManager.PlayOneShot(_settings.FallawayFloor.FMODEvent); + FMODUnity.RuntimeManager.PlayOneShot(_settings.FallawayFloor.FMODEvent, transform.position ); if (_graphics.TryGetComponent(out BoxCollider box)) box.enabled = false; diff --git a/game/Assets/Scripts/Traps/RollingBoulder.cs b/game/Assets/Scripts/Traps/RollingBoulder.cs index 53e6ce0..aa28501 100644 --- a/game/Assets/Scripts/Traps/RollingBoulder.cs +++ b/game/Assets/Scripts/Traps/RollingBoulder.cs @@ -1,8 +1,12 @@ using Ktyl.Util; using System.Collections; +using FMOD.Studio; +using FMODUnity; using PathCreation; using UnityEngine; using UnityEngine.Serialization; +using UnityEngine.UIElements; +using STOP_MODE = FMOD.Studio.STOP_MODE; #if UNITY_EDITOR using UnityEditor; #endif @@ -22,6 +26,13 @@ public class RollingBoulder : MonoBehaviour private bool _triggered = false; private bool _stopped; + private EventInstance _fmodEvent; + + void Start() + { + _fmodEvent = RuntimeManager.CreateInstance( _fmodKey ); + RuntimeManager.AttachInstanceToGameObject( _fmodEvent, boulderMove.transform, (Rigidbody)null ); + } private void Update() { @@ -47,7 +58,7 @@ public class RollingBoulder : MonoBehaviour { if (_triggered) return; - FMODUnity.RuntimeManager.PlayOneShot(_fmodKey); + _fmodEvent.start(); StartCoroutine(RollingStone()); } @@ -93,6 +104,7 @@ public class RollingBoulder : MonoBehaviour _triggered = false; _killbox.enabled = true; _stopped = false; + _fmodEvent.stop( STOP_MODE.IMMEDIATE ); } } diff --git a/game/FMOD Project/Assets/CaiStuff/Enviroment/Place.mp3 b/game/FMOD Project/Assets/CaiStuff/Enviroment/Place.mp3 new file mode 100644 index 0000000..c96024c --- /dev/null +++ b/game/FMOD Project/Assets/CaiStuff/Enviroment/Place.mp3 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:595565a8f42bef540dbdf593afaca85b5dae6a80c009a6750f7d2f3d1fc47166 +size 22224 diff --git a/game/FMOD Project/Assets/VO/English/so_much_pain_fixed.mp3 b/game/FMOD Project/Assets/VO/English/so_much_pain_fixed.mp3 new file mode 100644 index 0000000..0969262 --- /dev/null +++ b/game/FMOD Project/Assets/VO/English/so_much_pain_fixed.mp3 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0c635ad37a4255146457ab3e1a9c99474dc45c74ee6b5bc506079fc017c388b +size 679362 diff --git a/game/FMOD Project/Build/Desktop/Master.strings.bank b/game/FMOD Project/Build/Desktop/Master.strings.bank index 3fa1e22..0e62e60 100644 --- a/game/FMOD Project/Build/Desktop/Master.strings.bank +++ b/game/FMOD Project/Build/Desktop/Master.strings.bank @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f7e1cbd22144c6840145e48e034836b37cc2a0b863b77c536084fdecc6f0f76c -size 2566 +oid sha256:b9cf3c563d0b7a7663923b6f0a966404fabeee35da625fa95982f46f98d80b4e +size 2612 diff --git a/game/FMOD Project/Build/Desktop/SFX.bank b/game/FMOD Project/Build/Desktop/SFX.bank index 72fb24e..45335b8 100644 --- a/game/FMOD Project/Build/Desktop/SFX.bank +++ b/game/FMOD Project/Build/Desktop/SFX.bank @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b3b3f495fb354144cfdca41f82fcad42d91515fb17321bdb911e110713a5320 -size 4169312 +oid sha256:c39ff3489a1a29374429a0fde9be9ba71dc530377657fb54f2e0ddca1b965246 +size 4170016 diff --git a/game/FMOD Project/Build/Desktop/VO.bank b/game/FMOD Project/Build/Desktop/VO.bank index 2e27e7d..b9d87a3 100644 --- a/game/FMOD Project/Build/Desktop/VO.bank +++ b/game/FMOD Project/Build/Desktop/VO.bank @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c36c5658dbe443f0e036b758a8ceb971072ff7eec385f8a7f7fd6ee25884db97 -size 2946016 +oid sha256:2b1524c6c89555f5a7650aae7e2ac20d78c110c2fa16f247cb0126679333c031 +size 3231424 diff --git a/game/FMOD Project/Metadata/AudioFile/{22b542f4-f999-4aaf-ad1d-2b9ab1436c43}.xml b/game/FMOD Project/Metadata/AudioFile/{22b542f4-f999-4aaf-ad1d-2b9ab1436c43}.xml new file mode 100644 index 0000000..c5d8ca5 --- /dev/null +++ b/game/FMOD Project/Metadata/AudioFile/{22b542f4-f999-4aaf-ad1d-2b9ab1436c43}.xml @@ -0,0 +1,23 @@ + + + + + VO/English/so_much_pain_fixed.mp3 + + + true + + + 44.0999985 + + + 2 + + + 28.212244897959184 + + + {4c43130b-9186-4fb6-9d65-a9acdac70927} + + + diff --git a/game/FMOD Project/Metadata/Event/{14adad4f-74ed-4fc6-9b58-0cfbce4572f8}.xml b/game/FMOD Project/Metadata/Event/{14adad4f-74ed-4fc6-9b58-0cfbce4572f8}.xml index 358c689..d41009f 100644 --- a/game/FMOD Project/Metadata/Event/{14adad4f-74ed-4fc6-9b58-0cfbce4572f8}.xml +++ b/game/FMOD Project/Metadata/Event/{14adad4f-74ed-4fc6-9b58-0cfbce4572f8}.xml @@ -72,6 +72,9 @@ + + -8.5 + {a7c51766-5977-4bb0-99d7-4e37d94e3f80} diff --git a/game/FMOD Project/Metadata/Event/{17da375e-8c75-4269-937b-3a0a929e2c4b}.xml b/game/FMOD Project/Metadata/Event/{17da375e-8c75-4269-937b-3a0a929e2c4b}.xml index 66facc1..ae428e5 100644 --- a/game/FMOD Project/Metadata/Event/{17da375e-8c75-4269-937b-3a0a929e2c4b}.xml +++ b/game/FMOD Project/Metadata/Event/{17da375e-8c75-4269-937b-3a0a929e2c4b}.xml @@ -23,7 +23,7 @@ {cc109f4f-402e-49f8-b04c-96931c1045cf} - {ec03059a-97ee-4f05-b0a6-33494fe709a8} + {eb781a30-4072-44ac-8be7-0b2ec48e6008} {b6eddb92-cf88-4747-b34e-c83c5c474480} @@ -57,10 +57,11 @@ - + {1148c36a-8eb5-4ea4-be2a-c69e82888580} + {5355020a-d09b-4e4a-bfcc-089d57a4d67e} {4d7b7943-3517-410f-9f6d-f2e516e7880e} @@ -69,6 +70,7 @@ {1148c36a-8eb5-4ea4-be2a-c69e82888580} + {5355020a-d09b-4e4a-bfcc-089d57a4d67e} @@ -92,10 +94,33 @@ 5.416666666666667 + + 3.5 + + + {bd9155e9-4703-4391-a438-5e00ec534a2b} + {a6fe43c1-36b4-49de-a0b2-ab8533786b8a} + + + 1.5 + + + 9.75 + + + 2.5 + + + {1e7a9dd2-69f9-405e-a078-cbb61bd802da} + + + {36658820-a267-4523-8b92-e1c179cda4be} + + Audio 1 @@ -118,6 +143,28 @@ + + + {274404ad-b3d4-4321-ac0e-b908a9f3453f} + + + {dc441f68-54ca-45f3-ad09-2cdd1c6237c1} + + + {5355020a-d09b-4e4a-bfcc-089d57a4d67e} + + + + + {87c5b9b9-7c04-4f1d-b993-5e80c7550c9c} + + + {fea9b4e1-1337-408e-bda4-76847997d751} + + + {1148c36a-8eb5-4ea4-be2a-c69e82888580} + + {3e632582-6294-483a-b268-f0bf78c3a2ea} @@ -125,6 +172,51 @@ - + + + 6 + + + 95 + + + + + 1.5 + + + 1 + + + 1 + + + + + 5.416666666666667 + + + 0 + + + + + 1.5 + + + 0 + + + -1.00000048 + + + + + 5.416666666666667 + + + 1 + + diff --git a/game/FMOD Project/Metadata/Event/{601ea3ab-634e-4fd1-8e9e-44ed1f018ae4}.xml b/game/FMOD Project/Metadata/Event/{601ea3ab-634e-4fd1-8e9e-44ed1f018ae4}.xml new file mode 100644 index 0000000..dd86849 --- /dev/null +++ b/game/FMOD Project/Metadata/Event/{601ea3ab-634e-4fd1-8e9e-44ed1f018ae4}.xml @@ -0,0 +1,160 @@ + + + + + FuckedUpSpeech + + + 2 + + + {aacc9c7d-10bf-4006-bcdd-9a56dd0d03e4} + + + {05949128-2e39-425c-95c9-eeb260ee11cc} + + + {4d778dd6-4731-4747-a3ef-69a205738139} + + + {a90fe44b-2b78-407a-8e89-059a1a29b731} + + + {779848f8-eec4-4f2b-9752-a36e0cdc8282} + + + {1c0f16b8-a67a-43e5-9608-0c991995e9ac} + + + {0e2c7e3f-d445-4f3f-af6d-1a74b4ff8963} + + + {cd8c30f8-ff74-4f4c-947b-7f30fb11fd71} + + + {d6e4340a-dfdb-4393-b4dc-b55091d858cd} + + + + + {e0a8f4db-2b9d-4908-96bd-3c05a67da009} + + + + + {e0a8f4db-2b9d-4908-96bd-3c05a67da009} + + + + + {020a098a-f281-40e8-bde8-7d9742202d8e} + + + {8c5f5c73-fadf-4c52-a4ef-8f5ea624d9b7} + + + {af9d027a-3a1f-49a8-a9ef-4cbe20673632} + + + + + + + {fbd4e91c-b421-4dcb-96bd-92f15b76624e} + + + {d9442801-4b68-4a33-92d2-22cabf053e3c} + + + + + {fbd4e91c-b421-4dcb-96bd-92f15b76624e} + + + {d95517f5-e3a8-45b3-9656-127441c5dabd} + + + + + {5528048e-f65a-4daf-bf05-89282b270f3a} + + + {4b588dce-9db7-41bc-b948-48c04ece8c9d} + + + {05949128-2e39-425c-95c9-eeb260ee11cc} + + + + + {cfdcb981-d933-41d6-bca2-fd770f2ff0f4} + + + + + + 28.212244897959184 + + + {22b542f4-f999-4aaf-ad1d-2b9ab1436c43} + + + + + Audio 1 + + + {2de8a181-757c-49bd-9e49-9e6d34577348} + + + {8705cd5f-ef6a-4f56-8547-f55e6c1f568f} + + + {e0a8f4db-2b9d-4908-96bd-3c05a67da009} + + + + + 0.5 + + + 26.007389162561577 + + + {cd8c30f8-ff74-4f4c-947b-7f30fb11fd71} + + + {1c0f16b8-a67a-43e5-9608-0c991995e9ac} + + + + + {ce79b527-0ef0-44d7-a4e9-a24bdb7022e4} + {b63be8c9-e9b2-48e7-8ce6-bf50fab985f2} + + + + + + + {73ea28c9-df11-4ee1-aaed-dfe9524ff0fe} + + + + + + + 2 + + + 2.79999995 + + + 45 + + + 8000 + + + + diff --git a/game/FMOD Project/Metadata/Event/{80b1514b-07aa-4a1b-8663-346bf60403f1}.xml b/game/FMOD Project/Metadata/Event/{80b1514b-07aa-4a1b-8663-346bf60403f1}.xml index 291d295..0382975 100644 --- a/game/FMOD Project/Metadata/Event/{80b1514b-07aa-4a1b-8663-346bf60403f1}.xml +++ b/game/FMOD Project/Metadata/Event/{80b1514b-07aa-4a1b-8663-346bf60403f1}.xml @@ -72,6 +72,9 @@ + + 8.5 + {52bdf8e2-77c5-4c00-bd2c-adc125cfa393} diff --git a/game/FMOD Project/Metadata/Event/{d5ba71b3-85bc-4648-90ae-3a03a08cdefe}.xml b/game/FMOD Project/Metadata/Event/{d5ba71b3-85bc-4648-90ae-3a03a08cdefe}.xml index 13d94ea..811746f 100644 --- a/game/FMOD Project/Metadata/Event/{d5ba71b3-85bc-4648-90ae-3a03a08cdefe}.xml +++ b/game/FMOD Project/Metadata/Event/{d5ba71b3-85bc-4648-90ae-3a03a08cdefe}.xml @@ -72,6 +72,9 @@ + + -8.5 + {cf49e2c5-ce0c-469a-bb85-33f178ce9b0b}