42 lines
1.4 KiB
C#
42 lines
1.4 KiB
C#
using UnityEngine;
|
|
using TMPro;
|
|
|
|
public class AssistIntro : MonoBehaviour
|
|
{
|
|
[Header("UI 參照")]
|
|
[Tooltip("Dropdown")]
|
|
public TMP_Dropdown assistDropdown;
|
|
|
|
[Tooltip("Text (TMP)")]
|
|
public TextMeshProUGUI introDisplayText;
|
|
|
|
private readonly string[] intros = new string[]
|
|
{
|
|
" 不使用任何瞄準輔助,紀錄純淨的軌跡資料,使用你最純粹的反應力與控制力瞄準。如果可以的話,無輔助與有輔助的測試次數請盡量控制在 1 : 1。",
|
|
" 計算準心到敵方的向量,依照輔助強度的比例加到你的滑鼠移動上,把準心往敵方拉。輔助強度越高拉得越用力,100% 接近暴力鎖。敵方被擋住太多時不會觸發。",
|
|
" 依照敵方在螢幕上與你準心的距離,動態調整你的靈敏度(靠近敵方時降低、遠離時提高)。輔助強度為靈敏度變化程度。敵方被擋住太多時不會觸發。"
|
|
};
|
|
|
|
void Start()
|
|
{
|
|
if (assistDropdown != null)
|
|
{
|
|
UpdateIntro(assistDropdown.value);
|
|
|
|
assistDropdown.onValueChanged.AddListener(OnDropdownChanged);
|
|
}
|
|
}
|
|
|
|
void OnDropdownChanged(int index)
|
|
{
|
|
UpdateIntro(index);
|
|
}
|
|
|
|
void UpdateIntro(int index)
|
|
{
|
|
if (introDisplayText != null && index >= 0 && index < intros.Length)
|
|
{
|
|
introDisplayText.text = intros[index];
|
|
}
|
|
}
|
|
} |