Skip to content

XDEE2/EasyInputs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 

Repository files navigation

EasyInputs

XR Inputs Done Easily.

Documentation

Easy Hand Let's You Select Which Hand You Want To Get The Input From, There Are Two Values. LeftHand And RightHand Here Are Some Examples On How To Use It

RightHand

LeftHand

You Can Also Do A Value That You Can Edit In The Unity Editor

Value

HandAnimations

You Need To Use easyInputs If You Wanna Use EasyInputs!

using easyInputs;

If The Grip Button Is Down/Pressed.

EasyInputs.GetGripButtonDown(EasyHand easyHand);

Get's If The Trigger Button Is Down/Pressed.

EasyInputs.GetTriggerButtonDown(EasyHand easyHand);

Get's If The Trigger Button Is Touched. Only Works On Quest And You Need To Build For It To Work

EasyInputs.GetTriggerButtonTouched(EasyHand easyHand);

Get's The Grip Float.

EasyInputs.GetGripButtonFloat(EasyHand easyHand);

Get's The Trigger Float.

EasyInputs.GetTriggerButtonFloat(EasyHand easyHand);

Get's If The Primary Button is Down/Pressed. Example. A & X Button On Quest

EasyInputs.GetPrimaryButtonDown(EasyHand easyHand);

Get's If The Primary Button Is Touched. Example. A & X Button On Quest

EasyInputs.GetPrimaryButtonTouched(EasyHand easyHand);

Get's If The Secondary Button Is Down. Example. B & Y Button On Quest

EasyInputs.GetSecondaryButtonDown(EasyHand easyHand);

Get's If The Secondary Button Is Touched. Example. B & Y Button On Quest

EasyInputs.GetSecondaryButtonTouched(EasyHand easyHand);

Get's If The Thumbstick Is Down/Pressed.

EasyInputs.GetThumbStickButtonDown(EasyHand easyHand);

Get's If The Thumbstick Is Touched.

EasyInputs.GetThumbStickButtonTouched(EasyHand easyHand);

Get's The Thumbsticks Vector2, This Can Be Used For Movement And Turning

EasyInputs.GetThumbStick2DAxis(EasyHand easyHand);

Vibrates the Controller

StartCoroutine(EasyInputs.Vibration(easyHand, 0.15f, 0.15f))

How To Use

To Use A Button Down Function You Need To Do A If Statement

if (EasyInputs.GetThumbStickButtonDown(EasyHand.RightHand))
{
  Jump();
}

Or You Can Make It Equal A Boolean

bool CanJump = EasyInputs.GetThumbStickButtonDown(EasyHand.RightHand);

To Use A Button Float Function You Need To Make A Float

float GripValue = EasyInputs.GetGripButtonFloat(EasyHand.LeftHand);

To Use A Button Vector2 Function You Need To Make A Vector2

Vector2 JoyStick = EasyInputs.GetThumbStick2DAxis(EasyHand.LeftHand);

To Vibrate The Controller There is Multiple Settings, There is Amplitude And Duration

To Vibrate The Controller

//You choose which hand first then Amplitude And Then Duration
StartCoroutine(EasyInputs.Vibration(EasyHand.LeftHand, 0.15f, 0.15f))

About

XR Inputs Done Easily

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages