1
This commit is contained in:
@@ -15,6 +15,7 @@ using BITKit.SceneManagement;
|
||||
using BITKit.Selection;
|
||||
using BITKit.Steamwork;
|
||||
using UnityEditor;
|
||||
using UnityEngine.InputSystem.Interactions;
|
||||
|
||||
namespace BITFALL.UX
|
||||
{
|
||||
@@ -38,9 +39,8 @@ namespace BITFALL.UX
|
||||
[SerializeField] private UXBar armorBar;
|
||||
|
||||
[Header(Constant.Header.Input)]
|
||||
public InputActionReference inventoryAction;
|
||||
public InputActionReference returnAction;
|
||||
public InputActionGroup inputActionGroup = new();
|
||||
[SerializeField] private InputActionReference inventoryAction;
|
||||
[SerializeField] private InputActionReference returnAction;
|
||||
|
||||
[Inject]
|
||||
private IHealth _health;
|
||||
@@ -71,11 +71,6 @@ namespace BITFALL.UX
|
||||
{
|
||||
playerService.OnPlayerInitialized -= OnPlayerInitializedLocalPlayer;
|
||||
}
|
||||
protected override void OnEntryOrExit(bool isEntry)
|
||||
{
|
||||
inputActionGroup.RegisterCallback(inventoryAction, OnInventory);
|
||||
inputActionGroup.allowInput.SetElements(this, isEntry);
|
||||
}
|
||||
public void OnActive(ISelectable selectable)
|
||||
{
|
||||
seleableLabel.SetActive(false);
|
||||
@@ -131,7 +126,7 @@ namespace BITFALL.UX
|
||||
{
|
||||
if(playerService.LocalPlayer is null) return;
|
||||
if(_health.IsAlive is false) return;
|
||||
if(context.JustPressed())
|
||||
if(context is {interaction:PressInteraction,performed:true})
|
||||
UXService.Entry<UXInventory>();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user