31 lines
825 B
C#
31 lines
825 B
C#
using System;
|
|
using UnityEngine;
|
|
|
|
namespace AibisDream.FixSystem
|
|
{
|
|
[CreateAssetMenu(fileName = "WhackMoldData", menuName = "Level Data/WhackMoldData")]
|
|
public class WhackMoleData : ScriptableObject
|
|
{
|
|
[Header("基本参数")]
|
|
public float moleExistTime = 1f;
|
|
public int flickerFreq = 10;
|
|
public Vector2 batchDuration = new(2, 3);
|
|
public int totalBatchNum = 5;
|
|
public float batchGap = 1f;
|
|
|
|
[Header("批次序列")]
|
|
public WhackMoleBatch[] batches;
|
|
|
|
public WhackMoleBatch GetBatch(int index)
|
|
{
|
|
return index >= batches.Length ? batches[^1] : batches[index];
|
|
}
|
|
}
|
|
|
|
[Serializable]
|
|
public struct WhackMoleBatch
|
|
{
|
|
public int moleNum;
|
|
public Vector2 durationRange;
|
|
}
|
|
} |