26 lines
828 B
C#
26 lines
828 B
C#
using UnityEngine;
|
|
|
|
public class TargetPointData : MonoBehaviour
|
|
{
|
|
public WaveformType waveformType = WaveformType.Sine; // 正常波形类型
|
|
public bool isCorrect = true; // 是否为正确模块
|
|
//public WaveformType errorWaveformType = WaveformType.Spike; // 错误波形类型(如果有错误)
|
|
[HideInInspector]
|
|
public int randomShift;
|
|
[HideInInspector]
|
|
public float initialRandomPhase; // 随机初始相位
|
|
[HideInInspector]
|
|
public int spikeIndex=-1;
|
|
|
|
[HideInInspector]
|
|
public float sliderValue=-1;
|
|
|
|
void Start()
|
|
{
|
|
randomShift = Random.Range(7, 13);
|
|
initialRandomPhase = Mathf.PI * randomShift*0.1f; // 随机初始相位
|
|
//initialRandomPhase = Mathf.PI * 1f; // 随机初始相位
|
|
}
|
|
}
|
|
|