2021-03-17 19:04:31 +01:00
|
|
|
using System;
|
|
|
|
using System.Collections;
|
|
|
|
using System.Collections.Generic;
|
2021-03-17 19:37:56 +01:00
|
|
|
using DG.Tweening;
|
2021-03-17 19:04:31 +01:00
|
|
|
using Ktyl.Util;
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
[CreateAssetMenu(menuName = "KernelPanic/Traps/Settings")]
|
|
|
|
public class TrapSettings : ScriptableObject
|
|
|
|
{
|
2021-03-23 16:03:18 +01:00
|
|
|
public float SafeTime => _safeTime;
|
|
|
|
[Header("General")]
|
|
|
|
// how long the player has currently been safe for. -1 while the player is not
|
|
|
|
// in a safe zone
|
|
|
|
[SerializeField] private SerialFloat _safeTime;
|
|
|
|
|
2021-03-17 19:04:31 +01:00
|
|
|
[Serializable]
|
|
|
|
public struct FallawayFloorSettings
|
|
|
|
{
|
2021-03-23 16:03:18 +01:00
|
|
|
// how long the trap takes to reset while the player is in a safe zone
|
|
|
|
public float SafeResetTime => _safeResetTime;
|
|
|
|
[SerializeField] private float _safeResetTime;
|
|
|
|
|
2021-03-17 19:31:33 +01:00
|
|
|
public string FMODEvent => _fmodEvent;
|
|
|
|
[SerializeField] private string _fmodEvent;
|
|
|
|
|
|
|
|
public float ShakeStrength => _shakeStrength;
|
|
|
|
[Header("Animation")]
|
|
|
|
[SerializeField] private float _shakeStrength;
|
2021-03-17 19:37:56 +01:00
|
|
|
|
|
|
|
public Ease PopInEase => _popInEase;
|
|
|
|
[SerializeField] private Ease _popInEase;
|
2021-03-17 19:04:31 +01:00
|
|
|
}
|
|
|
|
public FallawayFloorSettings FallawayFloor => _fallawayFloor;
|
|
|
|
[SerializeField] private FallawayFloorSettings _fallawayFloor;
|
2021-03-18 18:25:34 +01:00
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
public struct ArrowWallSettings
|
|
|
|
{
|
2021-03-23 16:03:18 +01:00
|
|
|
public float SafeResetTime => _safeResetTime;
|
|
|
|
[SerializeField] private float _safeResetTime;
|
2021-03-18 18:25:34 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
public ArrowWallSettings ArrowWall => _arrowWall;
|
|
|
|
[SerializeField] private ArrowWallSettings _arrowWall;
|
2021-03-17 19:04:31 +01:00
|
|
|
}
|