diff --git a/game/Assets/Scripts/Traps/FallawayFloor.cs b/game/Assets/Scripts/Traps/FallawayFloor.cs index d1f205a..683b716 100644 --- a/game/Assets/Scripts/Traps/FallawayFloor.cs +++ b/game/Assets/Scripts/Traps/FallawayFloor.cs @@ -37,6 +37,12 @@ public class FallawayFloor : MonoBehaviour if (_settings.FallawayFloor.CanRespawn) { Reset(); + + // pop in animation + transform.localScale = Vector3.zero; + transform + .DOScale(Vector3.one, 0.5f) + .SetEase(_settings.FallawayFloor.PopInEase); } } diff --git a/game/Assets/Scripts/Traps/TrapSettings.cs b/game/Assets/Scripts/Traps/TrapSettings.cs index dfc3175..3179611 100644 --- a/game/Assets/Scripts/Traps/TrapSettings.cs +++ b/game/Assets/Scripts/Traps/TrapSettings.cs @@ -1,6 +1,7 @@ using System; using System.Collections; using System.Collections.Generic; +using DG.Tweening; using Ktyl.Util; using UnityEngine; @@ -24,6 +25,9 @@ public class TrapSettings : ScriptableObject public float ShakeStrength => _shakeStrength; [Header("Animation")] [SerializeField] private float _shakeStrength; + + public Ease PopInEase => _popInEase; + [SerializeField] private Ease _popInEase; } public FallawayFloorSettings FallawayFloor => _fallawayFloor; [SerializeField] private FallawayFloorSettings _fallawayFloor; diff --git a/game/Assets/Settings/Traps/Trap Settings.asset b/game/Assets/Settings/Traps/Trap Settings.asset index 5b3afb8..5f04d47 100644 --- a/game/Assets/Settings/Traps/Trap Settings.asset +++ b/game/Assets/Settings/Traps/Trap Settings.asset @@ -17,3 +17,4 @@ MonoBehaviour: _respawnTime: {fileID: 11400000, guid: 1d2951ab5083d4d48a319ff00a9eb8bd, type: 2} _safeTime: {fileID: 11400000, guid: 27c10a061baeec8469e96d4f995c1445, type: 2} _shakeStrength: 0.1 + _popInEase: 27