Home Unreal Engine

[Blueprint] Make static mesh array

polycounter lvl 6
Offline / Send Message
mickeyvpn polycounter lvl 6
Hey guys,

I'm trying to make a blueprint in Unreal Engine that will create static mesh array and place them on top of pedestal.
I describe overall logic like this:
  1. add meshes as components to blueprint

  2. define tag for meshes that will be top of the pedestal
  3. in construction script make array from components with specified tag
  4. get bounds for every mesh in array
  5. move each mesh of the array to new location relative to previous mesh in the array, vector value based on bounds of the meshes(i.e. big mesh will move farther than small one, in this way distance between meshes will not be constant)
  6. add pedestal to new location of each mesh
  7. place each mesh on top of their pedestal

So question is how to move object to new position relative to previous object in array? And how to duplicate mesh and move it to new position via blueprint(i.e. place pedestal below every mesh in array)?
I only managed to make blueprint that place mesh on top of the pedestal and scale the pedestal to fit mesh bounds. But problem is that it works fine only for one mesh.
Here is blueprints:
BP_Pedestal
BP_Array - little help here, because it move every index in array compare to scene root

Thank you.

Replies

  • Obscura
    Offline / Send Message
    Obscura grand marshal polycounter
    Why do you need a procedural mesh? This complicates things and makes it much more expensive. Is there something that you would want and a simple static mesh wouldn't do?
  • mickeyvpn
    Offline / Send Message
    mickeyvpn polycounter lvl 6
    Hi @Obscura

    It definitely will be possible to do manually in the level, but I thought that it can be more productive to make it procedural. Thing is I want to be able swap geometry inside blueprint. In screenshots I placed only three meshes, but I plan to make much bigger arrays, like ten or twenty objects in array. And there will be different arrays in different levels. So if I will do it manually it will take some time. But if I managed to do it via blueprint all I need to do is just swap meshes in blueprint and array will be ready to go.
  • Obscura
    Offline / Send Message
    Obscura grand marshal polycounter
    I think we are misunderstanding each other here. There is a class called procedural mesh and it has ability to change topology at runtime. There is also static mesh component. On your screenshots I see static mesh components which can be added easily via blueprints. And they are not equal to procedural mesh.
  • mickeyvpn
    Offline / Send Message
    mickeyvpn polycounter lvl 6
    Got it, my bad at clarifying what type of class I want to use. So, I want to use only static mesh components not procedural mesh.

    Changed topic title to to avoid misunderstanding.
Sign In or Register to comment.