A game about forced loneliness, made by TACStudios
1using System.Runtime.InteropServices;
2using UnityEngine.InputSystem.Utilities;
3
4namespace UnityEngine.InputSystem.LowLevel
5{
6 /// <summary>
7 /// Command to find out whether a device is currently enabled or not.
8 /// </summary>
9 [StructLayout(LayoutKind.Explicit, Size = kSize)]
10 public struct QueryEnabledStateCommand : IInputDeviceCommandInfo
11 {
12 public static FourCC Type => new FourCC('Q', 'E', 'N', 'B');
13
14 internal const int kSize = InputDeviceCommand.kBaseCommandSize + sizeof(bool);
15
16 [FieldOffset(0)]
17 public InputDeviceCommand baseCommand;
18
19 [FieldOffset(InputDeviceCommand.kBaseCommandSize)]
20 public bool isEnabled;
21
22 public FourCC typeStatic => Type;
23
24 public static QueryEnabledStateCommand Create()
25 {
26 return new QueryEnabledStateCommand
27 {
28 baseCommand = new InputDeviceCommand(Type, kSize)
29 };
30 }
31 }
32}