x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Implementing Reload with Motion Controller

Hello,

I need help. Again!!!

I am working on a shooter in VR and I need to implement Reload functionality with motion controllers something like swing your gun to reload (gunstringer kinect style). I am doing it by getting linear velocity of mesh attached to motion controller and checking change in velocity with previous velocity but its not working fine.

Can anyone help me out please.

Product Version: UE 4.13
Tags:
more ▼

asked Jan 09 '17 at 11:54 AM in VR

avatar image

Shivam.Dhoot
101 7 9 20

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Are you doing this in blueprint or C++? If you're using the node "Get Velocity", it returns the relative velocity of the components' parent. Which in this case would be 0 since the motioncontroller and the mesh is both moving at the same velocity. Try this out:

AverageVelocity = DeltaLocation/DeltaTime

Record previous location at the end of tick, on new tick you subtract current location from it and divide it by delta seconds = velocity

There is also a good plugin called "Gesture Tracker VR", but what I mentioned above is probably easier to implement. Good luck!

more ▼

answered Jan 11 '17 at 06:13 AM

avatar image

Fantasifall
234 5 7 15

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question