playMaker

Author Topic: VR: Get velocity to throw an object  (Read 574 times)

ToxicFrog

  • Beta Group
  • Full Member
  • *
  • Posts: 139
VR: Get velocity to throw an object
« on: May 24, 2021, 06:15:02 PM »
Hi Playmakers,

I'm working on a VR app. Previously, I'd used VRTK, but it seems to be almost abandoned at this point, so I'm rolling my own this time.

Here's my question:
Once I've grabbed an object, I turn off the object's gravity and set it to kinematic. When I release, I turn gravity back on and kinematic off.

But, it just falls to the floor. I need to throw it. What would you recommend for getting the velocity and applying it to the object when it's ungrabbed?

I appreciate any help!

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: VR: Get velocity to throw an object
« Reply #1 on: May 25, 2021, 11:42:38 AM »
Hi.
i think something like 'Get Velocity' on the hand that's holding the object. then on release after Kinematic is off, do a set velocity on the object.