Let’s start by creating a new function, which will contain the whole process (you are free to apply the exact same principles as Events or any other set up). Let’s call it MyPointCloudFunction.
Once the function is ready, add a local variable and call it MyPoints. Set the type of this variable to Point Cloud Point and convert it to an array by right-clicking on the blue bar symbol to the left of the name. This array will hold our intermediate data.
Now we can proceed to build the actual process, starting with populating our newly created array. For the purpose of this example, the array will be injected with 1000 randomly positioned, red points.
Now we need to construct an empty Point Cloud asset to assign the point data to. We will also save it as a local variable for later use.
Following this, we need to assign our populated array as data for this Cloud. We will also automatically rebuild all internal structures for the data.
Alternatively, you can opt for not rebuilding the Cloud straight away, and instead manually call the Rebuild function at some other time.
At this point you can do with the asset as you would with one imported through the Content Browser. In this example, we'll assign it to some hypothetical Point Cloud Actor.
And that’s it - once the code or Blueprint is executed you should have a brand new, sphere-shaped, red Point Cloud, like this:
Here are the full code snippet and full-sized Blueprint screenshot of the complete process.