2024-01-22 23:38:37 +03:00
|
|
|
using Syntriax.Engine.Core.Abstract;
|
|
|
|
|
|
|
|
namespace Syntriax.Engine.Input;
|
|
|
|
|
|
|
|
public interface IButtonInputs<T> : IAssignableStateEnable
|
|
|
|
{
|
2024-09-25 14:36:57 +03:00
|
|
|
void RegisterOnPress(T button, ButtonCallbackDelegate callback);
|
|
|
|
void UnregisterOnPress(T button, ButtonCallbackDelegate callback);
|
|
|
|
void RegisterOnRelease(T button, ButtonCallbackDelegate callback);
|
|
|
|
void UnregisterOnRelease(T button, ButtonCallbackDelegate callback);
|
2024-01-22 23:38:37 +03:00
|
|
|
|
|
|
|
bool IsPressed(T button);
|
|
|
|
bool WasPressed(T button);
|
2024-09-25 14:36:57 +03:00
|
|
|
|
|
|
|
delegate void ButtonCallbackDelegate(IButtonInputs<T> buttonInputs, T button);
|
2024-01-22 23:38:37 +03:00
|
|
|
}
|