Where are inputs?
Where is the input reference?
Changing the Input:
FBInventoryManager:
private void Update()
{
// Detect inventory toggle input
if (Input.GetKeyDown(inventoryKey))
{
// Toggle inventory UI open/closed
FBUIManager.instance.OpenInventory();
}
}FBInteractor:
// If we currently have an interactable object
if (raycastedObj != null)
{
// When the interact key is pressed
if (Input.GetKeyDown(interactKey))
{
// Call the object's interaction logic
raycastedObj.ObjectInteract();
}
}Last updated