rdBuildBuddy Tutorial 6 – Creating Instances using Light Weight Instances.
Last Updated 8th January 2023
UE5 introduces a new built-in plugin (experimental at time of writing) that manages Instanced Static Meshes. The system is called “Light Weight Instances”.
Please note that it does seem to crash quite regularly at present.
To get a better idea of what this is, here is a Tutorial posted by UE Forum member nRiman:
This tutorial is a simple example of adding some objects to our scene in UE5.1 using the LightWeight Instances.
Step 1. Ensure the LightWeight Instance Plugin is Enabled
The first things to note, is that it is a plugin, and it is experimental and it’s UE5 only. It’s not enabled by default, so you’ll need to go to your “Plugins” window (from the Edit Menu) and find it, then enable:
Step 2. Download this LightWeightInstance (LWI) SubClass
Now Download This Blueprint and unzip to your project. This is the Custom Object Factory built using LWI’s.
LWI’s are useful for making Blueprint type objects that have functionality and/or destruction etc into instances when not needed, and then converting them back to actors when you want to interact with them.
This tutorial creates a forest of tree actors – the inference is that you can easily add code to the tree blueprint to chop it down etc.
Step 3. Create our Tree Blueprint
Our first Blueprint is the Tree Blueprint – it has two states – uncut (0) and cut (1) – when cut, it renders at 90 degrees.
Step 4. Create our Tree LWI Blueprint
Create a New Blueprint, and set it’s parent to “LightWeightInstanceStaticMeshManager” – that’s the Blueprint class for getting the LWI’s to work.
In That Blueprint, set the RepresentedClass to our BP_Tree and set the Static Mesh in the ISMC to our SM_Tree4 mesh.
Note: I haven’t been able to get past this point – it always crashes when I try and select a mesh. I will continue this Tutorial once a fix is released.