2025-10-15 21:31:13 +08:00
|
|
|
|
using UnityEngine;
|
2025-10-17 15:10:19 +08:00
|
|
|
|
namespace Interface
|
2025-10-15 21:31:13 +08:00
|
|
|
|
{
|
|
|
|
|
public interface IInteractable
|
|
|
|
|
{
|
|
|
|
|
string GetInteractPrompt(); // 返回提示文字,例如“按E打开门”
|
|
|
|
|
void Interact(GameObject interactor); // 当玩家交互时触发
|
2025-10-17 15:10:19 +08:00
|
|
|
|
void OnGazeEnter(GameObject editor); // 玩家开始注视时触发
|
|
|
|
|
void OnGazeExit(GameObject editor); // 玩家停止注视时触发
|
2025-10-15 21:31:13 +08:00
|
|
|
|
}
|
|
|
|
|
}
|