diff --git a/Assets/01.Scenes/02.Combat.unity b/Assets/01.Scenes/02.Combat.unity index 47f09924b..dbf35fccb 100644 --- a/Assets/01.Scenes/02.Combat.unity +++ b/Assets/01.Scenes/02.Combat.unity @@ -10878,6 +10878,7 @@ MonoBehaviour: k__BackingField: {fileID: 36953787} k__BackingField: {fileID: 1011270532} k__BackingField: {fileID: 1213070730} + _dailyBgm: DailyBgm1 --- !u!4 &1597727070 Transform: m_ObjectHideFlags: 0 @@ -11365,69 +11366,6 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1704481408} m_CullTransparentMesh: 0 ---- !u!1 &1715186577 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1715186579} - - component: {fileID: 1715186578} - - component: {fileID: 1715186580} - m_Layer: 3 - m_Name: PostProcessingVolume - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!114 &1715186578 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1715186577} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 172515602e62fb746b5d573b38a5fe58, type: 3} - m_Name: - m_EditorClassIdentifier: - m_IsGlobal: 1 - priority: 0 - blendDistance: 0 - weight: 1 - sharedProfile: {fileID: 11400000, guid: da9f66a87cd612d4e847d191aa6df602, type: 2} ---- !u!4 &1715186579 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1715186577} - serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &1715186580 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1715186577} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d287dbc75fdbb6b44bd97e6d0604b227, type: 3} - m_Name: - m_EditorClassIdentifier: - _persistent: 1 --- !u!1 &1719893243 GameObject: m_ObjectHideFlags: 0 @@ -14481,6 +14419,63 @@ GameObject: m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 +--- !u!1001 &657457093462647415 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + serializedVersion: 3 + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1492562680585263202, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6468678730395126332, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} + propertyPath: m_Name + value: PostProcessingVolume + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_RemovedGameObjects: [] + m_AddedGameObjects: [] + m_AddedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: 29ff4b046e796f249b05a7e81fa48779, type: 3} --- !u!1 &657515045302343592 GameObject: m_ObjectHideFlags: 0 @@ -22922,7 +22917,7 @@ SceneRoots: - {fileID: 1184277681} - {fileID: 191889762} - {fileID: 2043119555} - - {fileID: 1715186579} + - {fileID: 657457093462647415} - {fileID: 1816611989} - {fileID: 882036795} - {fileID: 269653247} diff --git a/Assets/01.Scenes/02.Combat/CombatPostProcessingVolume.asset b/Assets/01.Scenes/02.Combat/CombatPostProcessingVolume.asset index 4afa566be..677d69c4e 100644 --- a/Assets/01.Scenes/02.Combat/CombatPostProcessingVolume.asset +++ b/Assets/01.Scenes/02.Combat/CombatPostProcessingVolume.asset @@ -108,7 +108,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 899c54efeace73346a0a16faa3afe726, type: 3} m_Name: Vignette m_EditorClassIdentifier: - active: 0 + active: 1 color: m_OverrideState: 1 m_Value: {r: 1, g: 0, b: 0, a: 1} @@ -117,7 +117,7 @@ MonoBehaviour: m_Value: {x: 0.5, y: 0.5} intensity: m_OverrideState: 1 - m_Value: 0.2 + m_Value: 0.15 smoothness: m_OverrideState: 1 m_Value: 1 diff --git a/Assets/02.Scripts/Character/Enemy/Boss/Rhinoceros/Rhinoceros.cs b/Assets/02.Scripts/Character/Enemy/Boss/Rhinoceros/Rhinoceros.cs index bc1699ce1..ab8ca8a7f 100644 --- a/Assets/02.Scripts/Character/Enemy/Boss/Rhinoceros/Rhinoceros.cs +++ b/Assets/02.Scripts/Character/Enemy/Boss/Rhinoceros/Rhinoceros.cs @@ -66,7 +66,7 @@ namespace BlueWater.Enemies.Bosses.Rhinoceros } AnimationController.SetAnimationTrigger("isDead"); - BossMapController.ClearMap(); + BossMapController.ClearMap(gameObject); while (AnimationController.GetCurrentAnimationNormalizedTime() <= 1f) { await Awaitable.NextFrameAsync(); diff --git a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/MiniSandMole.cs b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/MiniSandMole.cs index 608c24f66..a9ba06c95 100644 --- a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/MiniSandMole.cs +++ b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/MiniSandMole.cs @@ -61,6 +61,7 @@ namespace BlueWater.Enemies.Bosses.SandMole protected override async void Die() { BossSkillController.StopAllCoroutine(); + SandMoleStatus.StopAllCoroutine(); BehaviorTree.DisableBehavior(); StopMove(); diff --git a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMole.cs b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMole.cs index 5c3834f61..c3b8b1361 100644 --- a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMole.cs +++ b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMole.cs @@ -90,7 +90,7 @@ namespace BlueWater.Enemies.Bosses.SandMole SandMoleMapController = MapManager.Instance.SandMoleMapController; } - public override async void Initialize() + public override void Initialize() { StartCoroutine(InitializeCoroutine()); } @@ -133,6 +133,7 @@ namespace BlueWater.Enemies.Bosses.SandMole protected override async void Die() { BossSkillController.StopAllCoroutine(); + SandMoleStatus.StopAllCoroutine(); BehaviorTree.DisableBehavior(); StopMove(); @@ -145,7 +146,7 @@ namespace BlueWater.Enemies.Bosses.SandMole SpineController.SetSkin(SandMoleSkin.Idle.ToString()); var dieTrack = SpineController.PlayAnimation(SandMoleAnimation.Die.ToString(), false); - SandMoleMapController.ClearMap(); + SandMoleMapController.ClearMap(gameObject); await SpineController.WaitForAnimationCompletion(dieTrack); ItemManager.Instance.ItemDropRandomPosition(BossData.CharacterIdx, transform.position); diff --git a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMoleStatus.cs b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMoleStatus.cs index 2879cb72d..b99d473da 100644 --- a/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMoleStatus.cs +++ b/Assets/02.Scripts/Character/Enemy/Boss/SandMole/SandMoleStatus.cs @@ -1,4 +1,3 @@ -using System; using BlueWater.Interfaces; using BlueWater.Players; using BlueWater.Utility; @@ -66,5 +65,10 @@ namespace BlueWater.Enemies.Bosses.SandMole _stunParticle.Clear(); IsStunned = false; } + + public void StopAllCoroutine() + { + StopAllCoroutines(); + } } } \ No newline at end of file diff --git a/Assets/02.Scripts/Character/Enemy/Boss/TitanSlime/TitanSlime.cs b/Assets/02.Scripts/Character/Enemy/Boss/TitanSlime/TitanSlime.cs index fc95e255e..fa415b08e 100644 --- a/Assets/02.Scripts/Character/Enemy/Boss/TitanSlime/TitanSlime.cs +++ b/Assets/02.Scripts/Character/Enemy/Boss/TitanSlime/TitanSlime.cs @@ -75,7 +75,8 @@ namespace BlueWater.Enemies.Bosses.TitanSlime if (TitanSlimeState.Level == 4 && TitanSlimeState.HasRabbit) { ItemManager.Instance.ItemDropRandomPosition(BossData.CharacterIdx, transform.position); - _titanSlimeMapController.ClearMap(); + _titanSlimeMapController.ClearMap(gameObject); + Destroy(gameObject); return; } if (TitanSlimeState.Level <= 4) diff --git a/Assets/02.Scripts/Character/Player/Combat/CombatPlayer.cs b/Assets/02.Scripts/Character/Player/Combat/CombatPlayer.cs index 6250c3aa4..4793324ac 100644 --- a/Assets/02.Scripts/Character/Player/Combat/CombatPlayer.cs +++ b/Assets/02.Scripts/Character/Player/Combat/CombatPlayer.cs @@ -173,6 +173,9 @@ namespace BlueWater.Players.Combat CombatUiManager.Instance.GameOverPopupUi.Open(CombatUiManager.Instance.PopupUiList); } + public void ActivateInvincibility() => PlayerHealthPoint.ActivateInvincibility(); + public void DeactivateInvincibility() => PlayerHealthPoint.DeactivateInvincibility(); + public void SetCurrentHealthPoint(int value) => PlayerHealthPoint.SetCurrentHealthPoint(value); public void SetCurrentHealthPointMax() => PlayerHealthPoint.SetCurrentHealthPoint(PlayerHealthPoint.MaxHealthPoint); diff --git a/Assets/02.Scripts/Character/Player/PlayerHealthPoint.cs b/Assets/02.Scripts/Character/Player/PlayerHealthPoint.cs index cef591583..3e4935b34 100644 --- a/Assets/02.Scripts/Character/Player/PlayerHealthPoint.cs +++ b/Assets/02.Scripts/Character/Player/PlayerHealthPoint.cs @@ -28,6 +28,7 @@ namespace BlueWater.Players [field: SerializeField] public float InvincibilityDuration { get; private set; } = 0.5f; + [field: SerializeField] public bool IsInvincible { get; private set; } private WaitForSeconds _flashWhiteWaitTime; private Coroutine _flashWhiteCoroutine; @@ -160,5 +161,8 @@ namespace BlueWater.Players IsInvincible = false; Utils.EndUniqueCoroutine(this, ref _damageIntervalCoroutine); } + + public void ActivateInvincibility() => IsInvincible = true; + public void DeactivateInvincibility() => IsInvincible = false; } } \ No newline at end of file diff --git a/Assets/02.Scripts/Map/BossMapController.cs b/Assets/02.Scripts/Map/BossMapController.cs index c00a95b50..6c40d95b9 100644 --- a/Assets/02.Scripts/Map/BossMapController.cs +++ b/Assets/02.Scripts/Map/BossMapController.cs @@ -74,10 +74,10 @@ namespace BlueWater.Maps StartCoroutine(RestartMapCoroutine()); } - public override void ClearMap() + public override void ClearMap(GameObject bossObject) { IsCleared = true; - StartCoroutine(nameof(ClearMapCoroutine)); + StartCoroutine(ClearMapCoroutine(bossObject)); } protected virtual IEnumerator InitializeMapCoroutine() @@ -103,7 +103,6 @@ namespace BlueWater.Maps DataManager.Instance.CurrentSaveStage = SaveStage; CombatUiManager.Instance.FieldBossHealthPointUi.SetActiveHpSlider(false); - AudioManager.Instance.StopBgm(); CombatUiManager.Instance.FadeInOut(InitializeFadeInOutTime.x, InitializeFadeInOutTime.y, new Color(0f, 0f, 0f, 0f), 1f); @@ -119,8 +118,9 @@ namespace BlueWater.Maps OpenMapEntrances(); } - protected virtual IEnumerator ClearMapCoroutine() + protected virtual IEnumerator ClearMapCoroutine(GameObject bossObject) { + GameManager.Instance.CurrentCombatPlayer.ActivateInvincibility(); VisualFeedbackManager.Instance.SetBaseTimeScale(0.1f); CombatUiManager.Instance.FadeInOut(ClearFadeInOutTime.x, ClearFadeInOutTime.y); @@ -130,7 +130,7 @@ namespace BlueWater.Maps elapsedTime += Time.unscaledDeltaTime; yield return null; } - DestroyAllEnemiesExceptBoss(); + DestroyAllEnemiesExceptBoss(bossObject); VisualFeedbackManager.Instance.SetBaseTimeScale(1f); elapsedTime = 0f; @@ -141,6 +141,7 @@ namespace BlueWater.Maps } OpenMapEntrances(); + GameManager.Instance.CurrentCombatPlayer.DeactivateInvincibility(); } } } \ No newline at end of file diff --git a/Assets/02.Scripts/Map/FirstTutorialMapController.cs b/Assets/02.Scripts/Map/FirstTutorialMapController.cs index 56740fdd5..0dd9766cf 100644 --- a/Assets/02.Scripts/Map/FirstTutorialMapController.cs +++ b/Assets/02.Scripts/Map/FirstTutorialMapController.cs @@ -49,7 +49,7 @@ namespace BlueWater.Maps throw new System.NotImplementedException(); } - public override void ClearMap() + public override void ClearMap(GameObject bossObject) { throw new System.NotImplementedException(); } diff --git a/Assets/02.Scripts/Map/MapController.cs b/Assets/02.Scripts/Map/MapController.cs index da5790f4a..f591b4e5b 100644 --- a/Assets/02.Scripts/Map/MapController.cs +++ b/Assets/02.Scripts/Map/MapController.cs @@ -107,19 +107,12 @@ namespace BlueWater.Maps } } - public void DestroyAllEnemiesExceptBoss() + public void DestroyAllEnemiesExceptBoss(GameObject bossObject) { - var temps = new List(); foreach (Transform element in EnemyInstanceLocation) { - temps.Add(element); - } - - foreach (var element in temps) - { - var boss = element.GetComponent(); - if (boss) continue; - + if (element.gameObject == bossObject) continue; + Destroy(element.gameObject); } } @@ -163,11 +156,10 @@ namespace BlueWater.Maps GameManager.Instance.CurrentCombatPlayer.transform.position = PlayerSpawnLocation.position; CombatUiManager.Instance.FieldBossHealthPointUi.SetActiveHpSlider(false); - AudioManager.Instance.StopBgm(); } public abstract void ResetMap(bool isHardReset = false); public abstract void RestartMap(); - public abstract void ClearMap(); + public abstract void ClearMap(GameObject bossObject); } } \ No newline at end of file diff --git a/Assets/02.Scripts/Map/MapManager.cs b/Assets/02.Scripts/Map/MapManager.cs index f49eec3be..aede851d4 100644 --- a/Assets/02.Scripts/Map/MapManager.cs +++ b/Assets/02.Scripts/Map/MapManager.cs @@ -16,6 +16,9 @@ namespace BlueWater.Maps [field: SerializeField] public SandMoleMapController SandMoleMapController { get; private set; } + [SerializeField] + private string _dailyBgm = "DailyBgm1"; + private List _mapControllers; private MapController _currentMapController; @@ -29,6 +32,11 @@ namespace BlueWater.Maps }; } + private void Start() + { + AudioManager.Instance.PlayBgm(_dailyBgm); + } + public MapController GetMapController(SaveStage saveStage) { switch (saveStage) @@ -53,7 +61,7 @@ namespace BlueWater.Maps element.ResetMap(true); } GameManager.Instance.CurrentCombatPlayer.SetCurrentHealthPointMax(); - AudioManager.Instance.StopBgm(); + AudioManager.Instance.PlayBgm(_dailyBgm); } public void RestartCurrentMap() @@ -64,6 +72,7 @@ namespace BlueWater.Maps } _currentMapController = GetMapController(DataManager.Instance.CurrentSaveStage); _currentMapController.RestartMap(); + AudioManager.Instance.PlayBgm(_dailyBgm); } public void MoveSelectStage(int stage) @@ -76,6 +85,7 @@ namespace BlueWater.Maps var moveMapController = GetMapController((SaveStage)stage); moveMapController.MovePlayer(); + AudioManager.Instance.PlayBgm(_dailyBgm); } public void ForceKillCurrentBoss() diff --git a/Assets/02.Scripts/Map/TitanSlimeMapController.cs b/Assets/02.Scripts/Map/TitanSlimeMapController.cs index a9dcc9ff3..123e39c67 100644 --- a/Assets/02.Scripts/Map/TitanSlimeMapController.cs +++ b/Assets/02.Scripts/Map/TitanSlimeMapController.cs @@ -12,30 +12,30 @@ namespace BlueWater.Maps EnemyManager.Instance.InstantiateTitanSlime(BossSpawnTransform.position, 1, true, EnemyInstanceLocation); } - protected override IEnumerator ClearMapCoroutine() - { - DestroyAllEnemies(); - VisualFeedbackManager.Instance.SetBaseTimeScale(0.1f); - CombatUiManager.Instance.FadeInOut(ClearFadeInOutTime.x, ClearFadeInOutTime.y); - - var elapsedTime = 0f; - while (elapsedTime <= 3f) - { - elapsedTime += Time.unscaledDeltaTime; - yield return null; - } - DestroyAllEnemies(); - VisualFeedbackManager.Instance.SetBaseTimeScale(1f); - - elapsedTime = 0f; - while (elapsedTime <= 2f) - { - elapsedTime += Time.unscaledDeltaTime; - yield return null; - } - - OpenMapEntrances(); - //CombatUiManager.Instance.ClearPopupUi.Open(CombatUiManager.Instance.PopupUiList); - } + // protected override IEnumerator ClearMapCoroutine(GameObject bossObject) + // { + // DestroyAllEnemies(); + // GameManager.Instance.CurrentCombatPlayer.ActivateInvincibility(); + // VisualFeedbackManager.Instance.SetBaseTimeScale(0.1f); + // CombatUiManager.Instance.FadeInOut(ClearFadeInOutTime.x, ClearFadeInOutTime.y); + // + // var elapsedTime = 0f; + // while (elapsedTime <= 3f) + // { + // elapsedTime += Time.unscaledDeltaTime; + // yield return null; + // } + // DestroyAllEnemies(); + // VisualFeedbackManager.Instance.SetBaseTimeScale(1f); + // + // elapsedTime = 0f; + // while (elapsedTime <= 2f) + // { + // elapsedTime += Time.unscaledDeltaTime; + // yield return null; + // } + // + // OpenMapEntrances(); + // } } } \ No newline at end of file diff --git a/Assets/02.Scripts/PostProcessingManager.cs b/Assets/02.Scripts/PostProcessingManager.cs index a8d7a581a..a6c5271fc 100644 --- a/Assets/02.Scripts/PostProcessingManager.cs +++ b/Assets/02.Scripts/PostProcessingManager.cs @@ -1,5 +1,6 @@ using System.Collections; using BlueWater.Utility; +using Sirenix.OdinInspector; using UnityEngine; using UnityEngine.Rendering; using UnityEngine.Rendering.Universal; @@ -18,6 +19,20 @@ namespace BlueWater private ScriptableRendererData _currentRenderData; private Volume _currentVolume; private Coroutine _lowHpVignetteCoroutine; + + // LowHpVignette + [Title("LowHpVignette")] + [SerializeField] + private bool _isLerpIntensity = true; + + [SerializeField] + private float _startIntensity = 0.15f; + + [SerializeField, ShowIf("@_isLerpIntensity")] + private float _endIntensity = 0.2f; + + [SerializeField, ShowIf("@_isLerpIntensity")] + private float _lerpTime = 1f; protected override void OnAwake() { @@ -83,23 +98,22 @@ namespace BlueWater private IEnumerator LowHpVignetteCoroutine() { - var startValue = 0.2f; - var endValue = 0.3f; - var time = 0f; - var vignette = GetEffect(); - vignette.intensity.value = startValue; + vignette.intensity.value = _startIntensity; vignette.active = true; + if (!_isLerpIntensity) yield break; + + var elapsedTime = 0f; while (true) { - time += Time.deltaTime * 2f; - vignette.intensity.value = Mathf.Lerp(startValue, endValue, time); - if (time >= 1f) + vignette.intensity.value = Mathf.Lerp(_startIntensity, _endIntensity, elapsedTime); + if (elapsedTime >= _lerpTime) { - (startValue, endValue) = (endValue, startValue); - time = 0f; + (_startIntensity, _endIntensity) = (_endIntensity, _startIntensity); + elapsedTime = 0f; } + elapsedTime += Time.deltaTime; yield return null; } } diff --git a/Assets/02.Scripts/Prop/SpineDamageableProps.cs b/Assets/02.Scripts/Prop/SpineDamageableProps.cs index b21ef501a..83dae78b6 100644 --- a/Assets/02.Scripts/Prop/SpineDamageableProps.cs +++ b/Assets/02.Scripts/Prop/SpineDamageableProps.cs @@ -1,5 +1,7 @@ +using System.Collections; using BlueWater.Audios; using BlueWater.Players; +using BlueWater.Utility; using UnityEngine; namespace BlueWater @@ -18,6 +20,8 @@ namespace BlueWater [SerializeField] private string _dieAnimationName; + private Coroutine _touchCoroutineInstance; + private void Awake() { _spineController = GetComponent(); @@ -33,13 +37,18 @@ namespace BlueWater { if (!other.CompareTag("Player") || CurrentHealthPoint <= 0) return; - _spineController.PlayAnimation(_touchAnimationName, false); + Utils.StartUniqueCoroutine(this, ref _touchCoroutineInstance, TouchCoroutine()); } - - private void OnTriggerExit(Collider other) + + private IEnumerator TouchCoroutine() { - if (!other.CompareTag("Player") || CurrentHealthPoint <= 0) return; - + var touchTrack = _spineController.PlayAnimation(_touchAnimationName, false); + while (!touchTrack.IsComplete) + { + if (CurrentHealthPoint == 0) yield break; + + yield return null; + } _spineController.PlayAnimation(_idleAnimationName, true); } diff --git a/Assets/02.Scripts/ScriptableObject/Audio/BgmData.asset b/Assets/02.Scripts/ScriptableObject/Audio/BgmData.asset index 1560346ea..b1a459fd8 100644 --- a/Assets/02.Scripts/ScriptableObject/Audio/BgmData.asset +++ b/Assets/02.Scripts/ScriptableObject/Audio/BgmData.asset @@ -13,12 +13,15 @@ MonoBehaviour: m_Name: BgmData m_EditorClassIdentifier: k__BackingField: - - k__BackingField: TutorialStage - k__BackingField: {fileID: 8300000, guid: 7c619b42e5894ee4db14168ce657a8dd, - type: 3} - - k__BackingField: Stage1 - k__BackingField: {fileID: 8300000, guid: a7c4714bdbfdb764a8c19b58dbdf4d47, - type: 3} - - k__BackingField: Stage2 - k__BackingField: {fileID: 8300000, guid: 3120a718e36ab39419f53318deed3976, - type: 3} + - k__BackingField: DailyBgm1 + k__BackingField: {fileID: 8300000, guid: 7c619b42e5894ee4db14168ce657a8dd, type: 3} + - k__BackingField: DailyBgm2 + k__BackingField: {fileID: 8300000, guid: 3ba3ebbe3bd52984eb49c0cdb9656ceb, type: 3} + - k__BackingField: TitanSlimeMap + k__BackingField: {fileID: 8300000, guid: a7c4714bdbfdb764a8c19b58dbdf4d47, type: 3} + - k__BackingField: RhinocerosMap + k__BackingField: {fileID: 8300000, guid: 3120a718e36ab39419f53318deed3976, type: 3} + - k__BackingField: SandMoleMap + k__BackingField: {fileID: 8300000, guid: 4914a1d514cce3f459a0af45d62eeeee, type: 3} + - k__BackingField: GhostBarrelMap + k__BackingField: {fileID: 8300000, guid: d1f140d54184dc7449198f540d98d305, type: 3} diff --git a/Assets/05.Prefabs/Characters/Enemies/Bosses/TitanSlime.prefab b/Assets/05.Prefabs/Characters/Enemies/Bosses/TitanSlime.prefab index 20f9f13b9..42a171970 100644 --- a/Assets/05.Prefabs/Characters/Enemies/Bosses/TitanSlime.prefab +++ b/Assets/05.Prefabs/Characters/Enemies/Bosses/TitanSlime.prefab @@ -26,7 +26,7 @@ Transform: m_GameObject: {fileID: 1016303419742354216} serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: -0.258819, w: 0.9659259} - m_LocalPosition: {x: 0, y: 0.22, z: 0.01} + m_LocalPosition: {x: 0, y: 0.22, z: 0} m_LocalScale: {x: 0.2, y: 0.2, z: 0.2} m_ConstrainProportionsScale: 1 m_Children: [] @@ -75,7 +75,7 @@ SpriteRenderer: m_LightmapParameters: {fileID: 0} m_SortingLayerID: 0 m_SortingLayer: 0 - m_SortingOrder: 5 + m_SortingOrder: 4 m_Sprite: {fileID: 21300000, guid: 1ddf647b8857bff45a83e009dbb9ec8c, type: 3} m_Color: {r: 1, g: 1, b: 1, a: 1} m_FlipX: 0 diff --git a/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab b/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab new file mode 100644 index 000000000..9cca0414d --- /dev/null +++ b/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab @@ -0,0 +1,65 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &6468678730395126332 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1492562680585263202} + - component: {fileID: 7932030668675567178} + - component: {fileID: 3481486763373117091} + m_Layer: 3 + m_Name: PostProcessingVolume + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1492562680585263202 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6468678730395126332} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &7932030668675567178 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6468678730395126332} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 172515602e62fb746b5d573b38a5fe58, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IsGlobal: 1 + priority: 0 + blendDistance: 0 + weight: 1 + sharedProfile: {fileID: 11400000, guid: da9f66a87cd612d4e847d191aa6df602, type: 2} +--- !u!114 &3481486763373117091 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6468678730395126332} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d287dbc75fdbb6b44bd97e6d0604b227, type: 3} + m_Name: + m_EditorClassIdentifier: + _persistent: 1 diff --git a/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab.meta b/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab.meta new file mode 100644 index 000000000..6e0d9fdad --- /dev/null +++ b/Assets/05.Prefabs/Managers/PostProcessingVolume.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 29ff4b046e796f249b05a7e81fa48779 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/05.Prefabs/Maps/MapControllers/RhinocerosMapController.prefab b/Assets/05.Prefabs/Maps/MapControllers/RhinocerosMapController.prefab index c92b9b4a1..2731ab643 100644 --- a/Assets/05.Prefabs/Maps/MapControllers/RhinocerosMapController.prefab +++ b/Assets/05.Prefabs/Maps/MapControllers/RhinocerosMapController.prefab @@ -3725,7 +3725,7 @@ MonoBehaviour: - {fileID: 5780826671245057235} - {fileID: 6690762032223832123} SaveStage: 4 - BgmName: Stage2 + BgmName: RhinocerosMap InitializeFadeInOutTime: {x: 0.2, y: 1} ClearFadeInOutTime: {x: 0.2, y: 0.3} BossSpawnTransform: {fileID: 1204009204749076978} diff --git a/Assets/05.Prefabs/Maps/MapControllers/SandMoleMapController.prefab b/Assets/05.Prefabs/Maps/MapControllers/SandMoleMapController.prefab index d76198ee8..570d39e5b 100644 --- a/Assets/05.Prefabs/Maps/MapControllers/SandMoleMapController.prefab +++ b/Assets/05.Prefabs/Maps/MapControllers/SandMoleMapController.prefab @@ -1680,7 +1680,7 @@ MonoBehaviour: - {fileID: 5373123456437408081} - {fileID: 2667497661582632679} SaveStage: 5 - BgmName: + BgmName: SandMoleMap InitializeFadeInOutTime: {x: 0.2, y: 1} ClearFadeInOutTime: {x: 0.2, y: 0.3} BossSpawnTransform: {fileID: 6522622582430961898} diff --git a/Assets/05.Prefabs/Maps/MapControllers/TitanSlimeMapController.prefab b/Assets/05.Prefabs/Maps/MapControllers/TitanSlimeMapController.prefab index 728b70ac9..019439feb 100644 --- a/Assets/05.Prefabs/Maps/MapControllers/TitanSlimeMapController.prefab +++ b/Assets/05.Prefabs/Maps/MapControllers/TitanSlimeMapController.prefab @@ -5218,7 +5218,7 @@ MonoBehaviour: - {fileID: 60991982810615371} - {fileID: 6632898035063951688} SaveStage: 3 - BgmName: Stage1 + BgmName: TitanSlimeMap InitializeFadeInOutTime: {x: 0.2, y: 1} ClearFadeInOutTime: {x: 0.2, y: 0.3} BossSpawnTransform: {fileID: 6522622582430961898} diff --git a/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeAttackedParticle.prefab b/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeAttackedParticle.prefab index f775ec64e..7737851f8 100644 --- a/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeAttackedParticle.prefab +++ b/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeAttackedParticle.prefab @@ -3851,7 +3851,7 @@ ParticleSystem: radiusScale: 1 collidesWith: serializedVersion: 2 - m_Bits: 64 + m_Bits: 192 maxCollisionShapes: 256 quality: 0 voxelSize: 0.5 diff --git a/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeDieParticle.prefab b/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeDieParticle.prefab index ed3e388df..0a78b0bd3 100644 --- a/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeDieParticle.prefab +++ b/Assets/05.Prefabs/Particles/Enemies/Bosses/TitanSlime/TitanSlimeDieParticle.prefab @@ -3851,7 +3851,7 @@ ParticleSystem: radiusScale: 1 collidesWith: serializedVersion: 2 - m_Bits: 64 + m_Bits: 192 maxCollisionShapes: 256 quality: 0 voxelSize: 0.5 diff --git a/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordAttackParticle.prefab b/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordAttackParticle.prefab index ecff714f0..dfee6bde8 100644 --- a/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordAttackParticle.prefab +++ b/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordAttackParticle.prefab @@ -19407,7 +19407,7 @@ ParticleSystem: serializedVersion: 8 lengthInSec: 1 simulationSpeed: 1 - stopAction: 0 + stopAction: 2 cullingMode: 3 ringBufferMode: 0 ringBufferLoopRange: {x: 0, y: 1} diff --git a/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordReadyParticle.prefab b/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordReadyParticle.prefab index f33e82236..44c068fed 100644 --- a/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordReadyParticle.prefab +++ b/Assets/05.Prefabs/Particles/Players/Combat/TheWaltzOfTheSwordReadyParticle.prefab @@ -4863,7 +4863,7 @@ ParticleSystem: serializedVersion: 8 lengthInSec: 0.3 simulationSpeed: 1 - stopAction: 0 + stopAction: 2 cullingMode: 3 ringBufferMode: 0 ringBufferLoopRange: {x: 0, y: 1} diff --git a/Assets/05.Prefabs/Props/Spines/SummerGrass01.prefab b/Assets/05.Prefabs/Props/Spines/SummerGrass01.prefab index 5b3593af0..de9d349e6 100644 --- a/Assets/05.Prefabs/Props/Spines/SummerGrass01.prefab +++ b/Assets/05.Prefabs/Props/Spines/SummerGrass01.prefab @@ -8,6 +8,10 @@ PrefabInstance: serializedVersion: 3 m_TransformParent: {fileID: 0} m_Modifications: + - target: {fileID: 1725476421927655530, guid: 384b448f89341e84bb003cb48e37bb7d, type: 3} + propertyPath: loop + value: 1 + objectReference: {fileID: 0} - target: {fileID: 1725476421927655530, guid: 384b448f89341e84bb003cb48e37bb7d, type: 3} propertyPath: _animationName value: Normal diff --git a/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3 b/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3 new file mode 100644 index 000000000..0db66f5bf Binary files /dev/null and b/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3 differ diff --git a/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3.meta b/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3.meta new file mode 100644 index 000000000..5a34704b4 --- /dev/null +++ b/Assets/06.Sounds/Bgm/Battle! (Wild Pokémon) medley.mp3.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 4914a1d514cce3f459a0af45d62eeeee +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/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3 b/Assets/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3 new file mode 100644 index 000000000..cd9a2c8a3 Binary files /dev/null and b/Assets/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3 differ diff --git a/Assets/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3.meta b/Assets/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3.meta new file mode 100644 index 000000000..fac3706d5 --- /dev/null +++ b/Assets/06.Sounds/Bgm/Ghost Pokemon - Halloween 2023 (320 kbps).mp3.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: d1f140d54184dc7449198f540d98d305 +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/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3 b/Assets/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3 new file mode 100644 index 000000000..3bcee2b2f Binary files /dev/null and b/Assets/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3 differ diff --git a/Assets/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3.meta b/Assets/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3.meta new file mode 100644 index 000000000..2acf464b2 --- /dev/null +++ b/Assets/06.Sounds/Bgm/Mysterious Forest - The Legend of Zelda_ Link's Awakening.mp3.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 3ba3ebbe3bd52984eb49c0cdb9656ceb +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: