Peter Swanson

Software Engineer

Full Stack Web Developer


The Code


This script allows the HTC VIVE controllers to hold and release virtual objects on contact.


The user can hold objects by resting their thumb on the right-hand touchpad.


The gun object will snap to the proper angle while held, thanks to the second script.




Touchpad_Pickup.cs - Hold objects by resting thumb on touchpad



Hold_Object_at_Fixed_Angle.cs - Snap objects to an angle when they are held