Lib.InputDetection.OnButtonStateChanged += OnButtonStateChanged;
private void OnButtonStateChanged(object sender, InputDetectionEventArgs e) {
// added e.Key, so you don't have to use a string like "Primary"
// only works for InteractablePreset.InteractionKey enum entries
if (e.Key == InteractablePreset.InteractionKey.LeanLeft && e.IsDown) {
// stuff
}
if (e.Key == InteractablePreset.InteractionKey.LeanRight && e.IsDown) {
// stuff
}
if (e.Key == InteractablePreset.InteractionKey.flashlight) {
// stuff
}
}
Note: There were two of these "keyenuminputdetection" feature branches... I was confused about why my branch was 3 commits behind but I don't think it's anything I did.
Enables this functionality:
Note: There were two of these "keyenuminputdetection" feature branches... I was confused about why my branch was 3 commits behind but I don't think it's anything I did.