Where are inputs?

Where is the input reference?

There are TWO input reference in this package and it is located below:

  • ExamineInteractor script has an input for interacting with objects with the raycast

  • ExamineItem script has an input for opening and closing the keypads

  • Edit the input keys in the ExamineInputManager script

Changing the Input:

ExamineInputManager:

public class KPInputManager : MonoBehaviour
{
    [Header("Raycast Pickup Input")]
    public KeyCode interactKey;
    public KeyCode closeKey;

    [Header("Trigger Inputs")]
    public KeyCode triggerInteractKey;

    public static KPInputManager instance;
}

ExamineItem:

private void Update()
{
    if (isOpen && Input.GetKeyDown(KPInputManager.instance.closeKey))
    {
        CloseKeypad();
    }
}

ExamineInteractor:

if (keypadItem != null)
{
    if (Input.GetKeyDown(KPInputManager.instance.interactKey))
    {
         keypadItem.ShowKeypad();
    }
}

Last updated