Blueprints for trigger actions

In this part of the Pluralsight tutorial “Making a VR Experience in Unreal Engine” we get into setting up a trigger capsule for our objects, then using Blueprints to create a PrintString when our gaze encounters the capsule surrounding the object.

Trigger Capsules
Trigger Capsules surrounding objects

We went into the Blueprint for the VR_Pawn and clicked on the Viewport tab at the top of the Blueprint to see the actual object in order to create a very long Cube that was parented to the camera. This allows us to touch or “Overlap” objects in the scene when the camera points at them.

VR Pawn Gaze
VR Pawn Gaze
Gaze misses trigger capsule
Gaze misses trigger capsule

When the gaze/pointer encounters the object, the PrintString prints the word “Hit” instead of “Miss”.

Next, we built the Blueprints to make the program print different words on the screen depending on which object it overlaps.

blueprint print screen
blueprint print screen

WAIT – there is a problem. When the gaze encounters the trigger, it prints the wrong description.

This is not the salamander!

I literally had my wires crossed. I corrected the PrintString outputs.

Corrected Blueprint
Corrected Blueprint

Now the Cauldron string is connected to the Cauldron trigger, same for salamander.

We have successfully demonstrated creating an event (PrintString) when the VR_Pawn camera pointer overlaps a Trigger Capsule.