A UE4 engine plugin that provide a blueprint interface to enable level editing while using VR Preview.
The plugin is HMD agnostic supporting any HMD that uses VR preview.
The plugin support basic level editing functionality which includes:
- Addition and deletion of basic actor types.
- Adjusting the transform of actors.
- Copy and pasting actors.
- Setting the material of StaticMeshActors.
- Setting the basic properties of lights.
The plugin also comes with an example interface that utilizes an Xbox controller
called BVRExamplePawn.
If you are not compiling UE4's engine from source you should download one of the latest precompilied windows binaries:
The contents of the plugin should be copied to your UE4 installation location.
so that the BlockingVR folder resides in the engines plugin folder.
i.e C:\UE4\Engine\Plugins\BlockingVR
Once copied over the plugin will need enabling and the engine restarting
by opening the plugin's window in UE4 and location the plugin under the "VR" subcategory.
BlockingVR currently does'nt support level streaming or world composition.
To use BlockingVR under these circumstances the sub-level umap file you wish to work on
should be opened directly in the editor.
With the plugin enabled every project with have a collection created called "BlockingVRCollection". This collection will be created at each editor startup if the collection does not already exist. Any actor, staticmesh, particle or material
assets added to this collection will show up in the blockingVRExamplePawn menu's for later use when editing. To understand how collections work please see the UE4 documentation on collections.
The BVRExamplePawn is an example interface that uses a standard Xbox controller for user input.
To enable the BVRExamplePawn simply switch your gamemode under world settings to "BVRExampleGameMode".
And then start VR preview. To disable simply switch your gamemode back.
- With no menu's current showing standard movement is controlled using the XBox controllers left and right sticks.
- The controllers left and right D-Pad are used for changing the context sesitive menu's.
- The controllers up and down D-Pad are used for changing the menu's selection.
- Left and right on the controllers Left Stick will change the current selections value.
- When using the color picker the Left Stick will move the cursor within the color wheel.
- When using the color picker the Right Stick up and down will alter the V value of HSV.
- With No menu's showing(or with the location context menu visible) the X button will cycle through location snap values for the movement of actors.
- With the scale context menu showing this will cycle through scale snap values.
- With the rotation context menu this will cycle though rotation snap values.
- With no menu's showing the Y button will delete the currently highlighted actor.
- With no menu's showing the Left Bumper will copy the currently highlighted actor.
- With no menu's showing the Right Bumper will Paste the copied actor at the cursors current location.
- With no menu's showing the A button will attempt to select the currently highlighted actor and bring up any relevent context menu's.
- The B button will Deselect the currently selected actor and/or exit current context menu's.
- the A button will attempt to spawn an actor of current type selected from context menu at the current cursor location.
- The Start button will toggle the visibility of all actor icons.
- The Back button will toggle the visibility of all light debug meshes.
- Right Stick Click will toggle dynamic lighting on and off.
- The Right Trigger will attempt to pickup/drop the currently highlighted actor.
- Available when selecting any selectable actor.
- Available when selecting any selectable actor.
- Available when selecting any selectable non-light actor.
- Available when any light is selected.
- Available when a point light is selected.
- Available when a spot light is selected.
- Available when a directional light is selected.
- Available when no actor is selected.
- Spawn the highlighted primative at current cursor location with A Button
- Available when no actor is selected.
- Spawn the highlighted light at current cursor location with A Button
- All new lights default to stationary mobility.
- Available when no actor is selected.
- Only visible if at least one actor has been added to the "BlockingVRCollection" collection.
- Spawn the highlighted actor at current cursor location with A Button
- if the actor has no collision you will not be able to delete/manipulate after.
- Available when no actor is selected.
- Only visible if at least one static mesh has been added to the "BlockingVRCollection" collection.
- Spawn the highlighted static mesh at current cursor location with A Button
- if the mesh has no collision you will not be able to delete/manipulate after.
- Available when no actor is selected.
- Only visible if at least one particle system has been added to the "BlockingVRCollection" collection.
- Spawn the highlighted particle system at current cursor location with A Button
- Available when no actor is selected.
- Only visible if at least one material has been added to the "BlockingVRCollection" collection.
- Attempt to apply the highlighted material to the currently highlighted StaticMeshActor with A Button
BlockingVR is essentially a collection of blueprint node's which can be used with whatever form of user input you wish to use.
In the BVRExamplePawn A "BlockingVRManager" is spawned at beginplay and all API calls are done though this manager; All changes are deferred in the editor until ApplyDeferredChanges() is called.
Below is a list of blueprint nodes most of which where used in BVRExamplePawn (Which can be found in "BlockingVR Content/Example").
####User Interface:
#####CreateActorThumbnailTexture
- Attempts to create a thumbnail for the given actor class.
- Returns NULL if failed.
#####CreateMeshThumbnailTexture
- Attempts to create a thumbnail for the given static mesh.
- Returns NULL if failed.
#####CreateParticleThumbnailTexture
- Attempts to create a thumbnail for the given particle system.
- Returns NULL if failed.
#####CreateMaterialThumbnailTexture
- Attempts to create a thumbnail for the given material.
- Returns NULL if failed.
- Populates a TArray with a list of asset's of type currently in the "BlockingVRCollection".
####Creation, Deletion, Modification:
- Should be called to apply the currently made changes to the editor world.
- Adds an Actor with the specific transform.
- Note: Actor's should have some form of collision to be modifiable.
- Note: You should use AddPIELight(), AddPIEParticle() and AddPIEStaticMesh() for there respective types.
- Adds an Light at the specific location.
- All new lights default to stationary mobility.
- Adds a particle with the specific transform.
- Adds a static mesh with the specific transform.
- Note: Meshes should have some form of collision to be modifiable.
- Use for deleting an actor regardless of type.
- Creates a copy of the actor at the specific location using the original actors scale and rotation.
- If the actor is a light then basic light properties will also be copied.
- If the actor is a static mesh actor then the mesh along with materials will also be copied.
- Set new transform for the actor.
- Set new location for the actor.
- With the option to snap the vector uniformly to the given snap size.
- Set new rotation for the actor.
- With the option to snap the rotator uniformly to the given snap size.
- Set new scale for the actor.
- With the option to snap the vector uniformly to the given snap size.
- Attempts to set the material of a StaticMeshActor.
####Lighting:
- Gets the current radius of a point light (required as this is not normally availible via blueprint).
- Gets the current radius of a spot light (required as this is not normally availible via blueprint).
- Set's the linear color of a light.
- Set's the intensity of a light.
- Enable or disable static shadows for a light.
#####SetPIELightDynamicShadows
- Enable or disable dynamic shadows for a light.
- Just as with the standard editor you may not immediately see any change until a light rebuild has occurred depending on the lights mobility.
- Enable or disable square falloff for a light.
#####SetPIELightTranslucentLighting
- Enable or disable translucent lighting for a light.
- Sets the radius for a point light.
- Sets the radius for a spot light.
- Sets the outer cone angle for a spot light.
- Sets the inner cone angle for a spot light.