pop-in animation on platform respawn
This commit is contained in:
parent
9037fd264c
commit
af519d2ffe
|
@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -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;
|
||||
|
|
|
@ -17,3 +17,4 @@ MonoBehaviour:
|
|||
_respawnTime: {fileID: 11400000, guid: 1d2951ab5083d4d48a319ff00a9eb8bd, type: 2}
|
||||
_safeTime: {fileID: 11400000, guid: 27c10a061baeec8469e96d4f995c1445, type: 2}
|
||||
_shakeStrength: 0.1
|
||||
_popInEase: 27
|
||||
|
|
Loading…
Reference in New Issue