using System.Collections; using System.Collections.Generic; using UnityEngine; public enum GamepadButton { Blank, // 方向键 Left, Right, Up, Down, // 操作键 Triangle, // △ Cross, // × Square, // □ Circle, // ○ } public struct Command { public GamepadButton code; // 指令码 public float time; // 触发时间 public int id; public static Command Blank = new Command(GamepadButton.Blank, 0); public Command(GamepadButton code, float time) { this.code = code; this.time = time; this.id = UIDManager.Acquire(); } }