Procedural Wall generation

Hey Everyone, I’m trying to create a procedural wall using blueprints by putting the number of meshes to be placed across X-axis and Z-axis. I followed a tutorial on YouTube which helped but the problem that I’m facing is that my BP doesn’t place the meshes across the ZX-axis, I will attach an image below for better understanding. I will also attach a screen-cap of my BP code in-case I’m doing something incorrect in my code.


From the image above the area marked with the question mark is not filled with meshes and I control the number and height of the meshes using my BP. Image is attached below for better understanding.
Unreal1
BP code screen-cap



Any help would be greatly appreciated!

1 Like

Hi there,
Welcome to the Forums.

Makes sense, the second branch of your sequence node adds only Z Axis.
Have you tried to combine both wires coming from the Sequence node into one?
image

You can add a select node to the Z make vector and only add to it if the “for loop” index is less or equal than the “number of meshes Z - 1”. Else, add “0”.

You have to imagine a grid:

These are cubes spawned with 2 ForLoops:

2 Likes

Hi L1z4rD89, thank you so much for the reply. Your help did the trick and it works perfectly. Once again thank you for your reply and your solution. Cheers! :slight_smile:

Hi L.F.A, I did that but unfortunately that did not work it just seems to add along the ZX-axis. I will attach a screen-cap below.


However I have pinned the solution to this thread it works perfectly, you might want to check it out in case you’re having some similar problem. Lastly, thanks a lot for the reply. Cheers!

2 Likes