This commit is contained in:
CortexCore
2025-03-09 13:38:23 +08:00
parent 8261a458e2
commit 18239a5ae4
67 changed files with 8573 additions and 831 deletions

View File

@@ -4,6 +4,7 @@ using UnityEngine;
using UnityEngine.InputSystem;
using System;
using System.Linq;
using UnityEngine.InputSystem.Controls;
namespace BITKit
{
@@ -11,7 +12,7 @@ namespace BITKit
{
public static bool JustPressed(this InputAction.CallbackContext self)
{
return self.interaction is null && self.started;
return self is { started:true, control: ButtonControl { wasPressedThisFrame: true , isPressed:true} };
}
public static InputAction RegisterCallback(this InputAction self, Action<InputAction.CallbackContext> action)
{