OnGamepadConnected and OnGamepadDisconnected

pull/51/head
cosmonaut 2023-11-13 10:54:31 -08:00
parent 352bb34f82
commit d9b5c588fb
1 changed files with 16 additions and 0 deletions

View File

@ -35,6 +35,22 @@ namespace MoonWorks.Input
/// </summary>
public VirtualButton AnyPressedButton { get; private set; }
public delegate void OnGamepadConnectedFunc();
/// <summary>
/// Called when a game pad has been connected.
/// </summary>
/// <param name="slot">The slot where the connection occurred.</param>
public OnGamepadConnectedFunc OnGamepadConnected;
public delegate void OnGamepadDisconnectedFunc();
/// <summary>
/// Called when a game pad has been disconnected.
/// </summary>
/// <param name="slot">The slot where the disconnection occurred.</param>
public OnGamepadDisconnectedFunc OnGamepadDisconnected;
internal Inputs()
{
Keyboard = new Keyboard();