VR Expansion Plugin

does the vr grip interface only use certain collision channels. i made a new one and anything with that channel no longer works. is there a way around that

never mind. after all day yesterday and today i found it.

Fixed it, though it didn’t take as many nodes as you used, also added an optional tracking sensor view to it. I don’t know if the default template fixed ? It is from their code, and to be honest I didn’t mess with the teleport stuff too much as I figure it was good enough as is and people know it.

As for aligning yourself at the start to world and room, that is gameplay related, so I won’t be adding that in, but some may find it interesting and useful. By default when unrotated the forward direction of the tracked space is the world X+ direction.

Thanks for the contribution.

Doesn’t surprise me - I’m still pretty new to Blueprint!

No problem - thanks very much for plugin!

Pushed a new commit to the plugin


Changed up how bIscolliding is handled for grips, doing a full single sweep now from
start to finish of the planned movement.

Think I used to do  and switched to overlaps, but overlaps are suffering from precision
issues and causing late update stutters.

 fixes some visual glitches with the late update settings of NotWhenColliding and NotWhenDoubleGrippingOrColliding

I get one error after update your plugin. Copied from VRExpPuginExample (master branch, 05.18.2018):
\Plugins\VRExpansionPlugin\Source\VRExpansionPlugin\Private\VRCharacterMovementComponent.cpp(4409): error C3861: ‘DrawDebugCapsule’: identifier not found
VRExpPuginExample works good.
Maybe, VRExpPuginExample don’t use IWYU. (PCHUsage in Build.cs)

UE4.19, vs2017;
My fixes:

  1. #include “Kismet/KismetSystemLibrary.h”
  2. change VRCharacterMovementComponent.cpp(4409): DrawDebugCapsule to UKismetSystemLibrary :: DrawDebugCapsule
  3. change 5th parameter: FRotator::ZeroRotator, and change last parameters.

Yeah that is compiled out in shipping, and not hit during debug I missed it.

However the correct change is just “include “DrawDebugHelpers.h”” at the top of the cpp. It’s uploaded with the correction.

The rollback code change is where that debug logic is.

I’m having the same issue when trying to build the latest (f6e2876) commit of the VR Expansion Template. Does anyone have any ideas? On a clean install of Windows 7 with Visual Stuido 2017 and UE 4.19.2

Yes. Thanks for support and plugin!

Hi guys!

I have one question. How we can change on the fly the settings in AdvancedGripSettings. I trying to deactivate AdvancedGripPhysicSettings when griping the second grip, without sucess.

Only view Set BPAdvGripSettings Structure and set members in structure but don’t change anything. I’m a bit lost with doing .

SetGripAdvancedPhysicsSettings is I think the only modifer that I don’t have a function for.

What about it are you trying to change? It is checked on replication but only changes the grip stiffness, however there isn’t much to AdvancedPhysicsSettings that should ever need to be changed during a grip, aside from the stiffness and damping and there is already a function for that.

Outside of the stiffness/damping the values are stored in the GripStructure itself once a grip takes place, you have to get the Grip of the object and set them there.

I used to simulate the weight. If is double griped, weight should be balanced (two hands is stronger that one) With method i could simulate a LAG on the movement. In real world, grip a rifle or large weapon with one Hand and have got aim is a bit complicated. With physic enable, Aceleration Constant, and angular damping and stiffness i got a better feel with one hand, and a penalization. I don’t want a RAMBO in my game with 2 AR, but if you like that, you can do, although a bit useless… but is the user and not me that decide that.

In a previous version, i applied a recoil, but in VR is strange the weapon move like a snake in all directions with one hands, isn’t intuitive.

Acceleration constraint is the default type, you are just changing the angular.

You should try using the SetGripStiffessAndDamping node instead it has an Option to set the angular values as well. Optionally, since you are altering a grip when you add the secondary attachment, you can also literally just edit the Grip structure itself for whatever values you want (if you are not client authority, client auth has to send a change up so you need to use the node).

For reference, when not using advanced settings I multiply the stiffness/damping by these values for the angular


// Constraint multipliers for angular, to avoid having to have two sets of stiffness/damping variables
const float ANGULAR_STIFFNESS_MULTIPLIER = 1.5f;
const float ANGULAR_DAMPING_MULTIPLIER = 1.4f;

Can use that for setting angular with the setter node for the same effect as turning off advanced settings.

I’m did a mistake or something. Okay, i did that you tell me. I set the GrippableSkeletalMesh as Angluar and Stiffnes in 20 for example. In the OnSecondaryGrip, i pick de GripInformation and HeldHand pass to SetGripStiffnessAndDamping and set custom value to 0 (is the default values, no?) But nothing happens. I don’t sure what i’m doing.

GripInformation store all the information on Predominant Hand, no?

I did , but it not change anything, i know i doing something wrong, for i don’t sure what i doing.

For Clientside_Movement grips you need to call that function on the server.

Regardless, you should be increasing the stiffness not setting it to zero? 0 stiffness/damping is an invalid number for constraints.

I ran a quick test and it worked fine.

Pushed a new commit to both repositories (actually is a list of recent changes)

Template



Changed controller model loading to be per hand and safe for oculus platform in the template

Corrected Epics roomscale rotation for teleport boundries (unsure if they fixed  in their base template ever).

Added optional tracking sensors to the teleport outline


Plugin



Added a GetControllerDeviceID node to the grip controller
Lets you get the XRsystem device id for the calling controller which is far easier than trying to match up ID lists to the specific controller.

Added a master check for windowsMR to the SteamHMDType node.
At some point need to branch it out to return each seperate HMD in MR

Added grip re-creation case for if the advanced physics settings were turned off

Added a config variable  / console variable for the rotation correction threshold with the new rotation rollback pathway.
vre.RotationCorrectionThreshold (default 0.02f)

 SetGripConstraintStiffNessAndDamping was setting the handle via the passed in grip struct  
 and not the modified original, corrected .  

 Also changed order of operations so that IsHeld is set prior to EventOnGrip and  
 NotifyGrip is called with the added grip information passed in so that OnGrips  
 that modify the grip information work correctly. 

Added a new entry under use cases ( time for a game jam game that I thought was pretty impressive for a 5 day deadline), not to mention not
working off of the example map but implementing from the ground up using the plugin.

Rise Of The Bots VR
https://slapunas./riseofthebotsvr

I’m going to cry. I don’t know nothing (hello, i’m John Snow). Okay i did your system. I pass it to the Server (but i’m the server in test) and aparently works. The Angular Stiffness and Damping change, i see it in log. But i don’t feel it, i feel the lag without change.

I set the variables in 10/10 to test with one Grip, and set to 100/100 with two grips. The stiffness change, but i don’t feel any change. The Weapon still moves with LAG.

If i set the GrippableActor in BP Settings to 100/100 at start, the weapon moves greatly well, how at default settings. Also, when i change the Stiffnes, on release secondary grip, the weapon drops. I don’t understand for what if i didn’t change anything more than the stiffness and damping.

But anyway, what is the default Stiffness and Damping when not set it in AdvancedGrip?

Default stiffness is 1500, you can see it in the grip settings struct, values of 100 are very low and 10-100 is barely a stiffness change.

The example gun uses 5000 stiffness.

In my case, it do nothing. I don’t want change the Constraint. But is the only that GripStiffnessAndDamping do in my tests. One pic to be clear.

I want to change these variables, is it that produces the effect that i want. is i set the Blueprint, but the Gun don’t affect and i don’t know what.

Custom Event is set to Server, but in Blueprintue don’t show.

Yes…like I said, the difference between 10/15 and 100/100 is nearly none, you are setting them to nearly the same values. Also you do not want damping to be nearly as much as the stiffness, it just gets rid of the stiffness then. That is why default is 1500/300.

I am looking into something though, there might also be a bug here