增加技能按钮说明
This commit is contained in:
@@ -22,7 +22,7 @@ namespace IndianOceanAssets.Engine2_5D
|
||||
|
||||
[Header("冷却")]
|
||||
[Tooltip("放置灵灯的冷却时间(秒)")]
|
||||
[SerializeField] private float cooldown = 5f;
|
||||
[SerializeField] private float cooldown = 3.5f;
|
||||
|
||||
[Header("灵灯预制体")]
|
||||
[SerializeField] private GameObject lanternPrefab;
|
||||
@@ -49,8 +49,8 @@ namespace IndianOceanAssets.Engine2_5D
|
||||
|
||||
private void Update()
|
||||
{
|
||||
// 按 U 且 CD 就绪 且 还有灵灯 → 放置
|
||||
if (Input.GetKeyDown(lanternKey)
|
||||
// 按 U 或鼠标左键 且 CD 就绪 且 还有灵灯 → 放置
|
||||
if ((Input.GetKeyDown(lanternKey) || Input.GetMouseButtonDown(0))
|
||||
&& _remainingLanterns > 0
|
||||
&& Time.time > _lastPlaceTime + cooldown
|
||||
&& lanternPrefab != null)
|
||||
|
||||
Reference in New Issue
Block a user