VR Expansion Plugin

I followed a tutorial that modified the VR Expansion download, I followed it and I was wondering if there is a way to get the teleport on and and the hover movement onto the joy stick.

Yeah change the input bindings and set the default movement modes. Everything regardling movement logic is handled in the blueprints for modifiability.

Sorry for the late reply, I just downloaded the example map and changed the mesh and settings of the dagger.

ok after i move the modes around is there anything else i have to do such as change anything in the begin event section?

Hi there, would it be possible to merge FPS C++ Template project into the VR Expansion Example project? My goal is to have both VR or non VR Controller in one project.

Not if you just want different default movement modes, if you are trying to change the stick to do two things at once though you need to script that yourself. Generally the switchable movement modes are just for testing for people anyway, should drop those off and just have it static which ones are current.

Yes, I wouldn’t see any issues generally, just use different player controllers for non VR / VR or handle the pawn spawning based on in vr or not (like template already does for the FPS testing pawn).

Hi ! First off, thank you so much for providing resource. It’s jumped my development so far forward and I’m very appreciative. You’re a saint. I have two quick questions if you don’t mind:

  1. What constitutes proper crediting according to the MIT license in the context of a UE4 shipped game? I’m wanting to get that right when the time comes, but opinions on the proper way to go about it differ.

  2. is not related to your plugin, but I was wondering if you had any knowledge of HTC Vive touchpads giving a negative output from a touch at the top of the pad, which should be positive.

Thank you!

  1. Pasting the license literally anywhere in the file system of the end software is good enough, ideally you would have a file where you credit your sourced code from for each so that you don’t need a bunch of seperate files. does not require an in program credit be given, or it to even be easily visible.

  2. If you roll all of the way off of the top zone I could see that, but no, I never experienced that back when I used wands still (its been awhile), so it could be down to a new bug or hardware issues with yours.

Sounds good, thanks!

EDIT: Is there a specific iteration of the license I should use that I can get from your website or do I just use the standard one?

1 Like

The plugin has one packaged with it as a LICENSE.txt file.

Got it. Should’ve caught that. While I’m already bothering you, could you recommend the best component of your VR Character setup to attach a Skeletal Mesh to for the purpose of an IK body/arm set up? I was trying VRRootReference as the parent but wasn’t seeing the mesh appear in game. Thank you again.

Hi, I am having a reoccurring problem with the VR Expansion Plugin. For some reason, the height of all of the vr characters will stop working randomly. The camera then just sits on the floor. I tried recalibrating my headset’s height, but that didn’t fix it. I didn’t change anything in my project to mess anything up as far as I know, so I have no idea why it keeps on happening. Is a common problem, and is there any way to fix it?

Attach it to the ParentRelativeAttachment component, you can toggle on a “floor level” mode on it to have it track at the feet of the player and offset your mesh as you wish.

That doesn’t have anything to do with the plugin itself, the camera auto follows the tracking system. Is the camera not moving at all or is it moving but from the floor height instead of room scale?

Using the latest template I still have these issues. I think it’s from an animation which is changing the scale of a bone and then grabbing from that bone. It can be replicated by making a pose for a skeletal mesh that has an increased size for one of the bones, and then grabbing from that bone.

Mmm, it wasn’t the grasping hand, the main gripping logic was registering per bone gripping on a scaled bone as the root object being misscaled.

I just committed a fix for that.

Hey, hope you don’t mind giving me a hand again. I’ve tried to sort out myself for a couple days and I’m running into a wall with the slotting system. Here’s my setup in C++:


IVRGripInterface* GripInterfaceForActor = Cast<IVRGripInterface>(HitResult.GetActor());

if (GripInterfaceForActor)
{
bool bHadSlotInRangeLocal = true;
FTransform SlotTransform;
FTransform HitActorTransform = HitActor->GetActorTransform();
GripInterfaceForComp->Execute_ClosestGripSlotInRange(HitActor, RightMotionControllerLocation, false, bHadSlotInRangeLocal, SlotTransform, RightMotionController, NAME_None);

FTransform TransformForHadSlot = HitActorTransform.GetRelativeTransform(SlotTransform);
FTransform TransformForNoSlot = RightMotionController->ConvertToControllerRelativeTransform(HitActorTransform);

FTransform FinalTransform;
if (bHadSlotInRangeLocal)
{
UE_LOG(LogTemp, Warning, TEXT("Had slot in range"))
FinalTransform = TransformForHadSlot;
}

if (!bHadSlotInRangeLocal)
{
UE_LOG(LogTemp, Warning, TEXT("Didn't have slot in range"))
FinalTransform = TransformForNoSlot;
}

// FTransform CompTransform = HitResult.GetComponent()->GetComponentTransform();
RightMotionController->GripObjectByInterface(HitResult.GetComponent(), FinalTransform, false);

**The problem is that when I grip with code, the object jumps/snaps *towards *my controller for a split second, then flies away a few meters with physics instead of snapping to my hand. **I have a VRGripP1 socket set up on the grippable static mesh, and it’s inside a BP based on the GrippableActor class. I wanted to figure out myself but I thought you might be able to quickly spot my mistake. Thank you!

That quoted snippet should be TRUE for the boolean, its been made into a relative transform so it needs to be listed as already relative, otherwise the gripping function will attempt to make it relative.

Got it. Now I’m having it trip line of code every time and just grabbing it in the normal offset fashion, still not snapping to the controller:



if (!bHadSlotInRangeLocal) { UE_LOG(LogTemp, Warning, TEXT("Didn't have slot in range")) FinalTransform = TransformForNoSlot; }

I have the slot range set in the grippable object’s BP to 200 so it’s well over far enough to be triggered. Slot Default Grip Type is however set to Interactive Collision With Physics, should that be something else? I’ll keep chipping away but if you think of anything else that could be wrong it’d be much appreciated

EDIT: Never mind, my BP instance was overriding it the pick up range variable PrimarySlotRange. Will leave up for anyone else having the same problem. Sorry for the mistake! You’re the best

Hi - new question: I see in the ‘Can Object Be Climbed’ function in Vive Pawn Character there is a ‘Get Collision Response To Channel ECC_GameTraceChannel1’ - what is ? I can’t find it defined in project settings. The effect is that I can climb on my enemy actor capsules which is super odd and not compatible with the ideas I have for my game :slight_smile: