VR Expansion Plugin

Hello friends, I had a question, why when I grab the gun in the sample file, it doesn’t release, but when I press the A key, it releases?
I work with version 5.2.

If I want to put something on the character’s hand and control it with the other hand, in your opinion, how can I do this more easily with the plugin?

The gun has some gameplay tags attached so that you don’t have to hold the button to keep gripping it. The examples inputs are per object tweakable via gameplay tags.

As for your second question, not sure what you mean by control it. But you can force the object to be held on begin play (or just attach to the hand sounds more like it from what you are saying).


rebuild 5.2 and 5.2 plugin but show this error when rebuild???

Show the output tab, also for 5.3 make sure you are on visual studio 2022.

Build started…
1>------ Build started: Project: VRExpPluginExample, Configuration: Development_Editor x64 ------
2>------ Skipped Build: Project: UE5, Configuration: BuiltWithUnrealBuildTool Win64 ------
2>Project not selected to build for this solution configuration
1>Using bundled DotNet SDK version: 6.0.302
1>Running UnrealBuildTool: dotnet “…..\Engine\Binaries\DotNET\UnrealBuildTool\UnrealBuildTool.dll” VRExpPluginExampleEditor Win64 Development -Project=“C:\Users\RASA\Downloads\Compressed\VRExpPluginExample-master\VRExpPluginExample.uproject” -WaitMutex -FromMsBuild
1>Log file: C:\Users\RASA\AppData\Local\UnrealBuildTool\Log.txt
1>Using ‘git status’ to determine working set for adaptive non-unity build (C:\Users\RASA\Downloads\Compressed\VRExpPluginExample-master).
1>Creating makefile for VRExpPluginExampleEditor (no existing makefile)
1>Could not find definition for module ‘AdvancedSessions’, (referenced via Target → VRExpPluginExample.Build.cs)
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.MakeFile.Targets(45,5): error MSB3073: The command ““H:\Program Files\Epic\UE_5.2\Engine\Build\BatchFiles\Build.bat” VRExpPluginExampleEditor Win64 Development -Project=“C:\Users\RASA\Downloads\Compressed\VRExpPluginExample-master\VRExpPluginExample.uproject” -WaitMutex -FromMsBuild” exited with code 6.
1>Done building project “VRExpPluginExample.vcxproj” – FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 1 skipped ==========

You downloaded the example project and it looks like you replaced the plugins folder? The example already always comes with the correct plugin version for it, and it uses AdvancedSessions to do test listen servers for multiplayer testing. Looks like you deleted it?

No, I took the sample and when I tried to open it with version 5.2, it gave me the XRBase error, so I had to replace the plugins in the sample with the plugin corresponding to the program version.

Do you think I should do something special to be able to open the sample file with 5.2? I am a newbie and I want to upgrade the mechanics of the game with your plugin.

No, just make sure you down load the sample that matches the plugin version you are trying to use. You downloaded master branch which is 5.3, if you download the 5.2-Locked branch then it should just compile as is. When you replaced the plugin folder you also removed an entire plugin.

Master/5.3 example also won’t work in 5.2 anyway because any BPs i have altered for 5.3 will be tagged as the newer engine version and will not function in 5.2.

1 Like

Thank you for your explanation, maybe you can give me some advice. I want to use an ampoule to increase life for the character, which path should I refer to in your training? Thank you for your advice.

As in they break the top or inject it? Not really sure what you mean.

Yes, above the left hand, I want to create a place to inject the ampoule and make an animation of the hand for injection so that the life of the character increases.

Not sure you should animate that, just actually have them move their hands to there and then attach the ampoule and have it track the hand downwards into the hand.

Do you think I should put collision sphere on the left hand after the right hand reaches the boundary of the sphere so that the ampoule spawns in the right hand? Or is it better to attach the same ampoule to the empty part for injection? After that, with an additional key, the injection animation will be played and the amount of life will increase on the widget.

Could do that, or could literally have the actual ampule attached on the hand and pick it up.

1 Like

Hello sir, I apologize for disturbing you again.
I wanted to ask, how can I do the animation of the hands when he has not touched anything yet? Do I have to give a separate blueprint in the BP_VRCharacter section in the Grab L/R trigger section?
If the left hand mesh is different from the right hand model, which part should I refer to? I changed the models in bp_VRCharacter and in the graspingHandManny section, but both hands are the right model?
In your opinion, how can I create a different mesh in the hands?

You can set the custom or idle pathway for the hands animation blueprint to animate a curl animation based on a scale or enum or something that you drive off of buttons sure. Both hands are the right model in the example as the left hand is mirrored in scale.

With the manny hands specifically they contain the skeleton for both hands in both sides so that isn’t really required, they can share the same animation blueprint, but things like the OpenXR hand tracking support would have to have a switch on it to use the left hand skeleton instead with the left hand.

So I can’t have 2 different hand meshes from the same skeleton? Because I always want the left hand to be a certain mesh and the right hand to be another mesh. I do not intend to change left or right.
Regarding the animation blueprint, could you explain clearly which part should I change so that it can move without holding hands? Thank you for showing a picture.

You can, I was saying that the manny hands have both the left and right hand bones inside of them. Which I assume was Epics way of making it easier to animate them since the same animation blueprint can be assigned to both.

The animation blueprint can be assigned to any mesh that uses the manny skeleton.

As for where to insert your custom posing, I would put it into the DefaultPose pin of the blend node:
image

That is the animation state when the hand is not actively being driven by hand tracking or gripping.

Or add it to the blend prior to it where it checks for the hand tracking and replace the idle animation:
image