Scale and Translate object by random factor

Hey guys,

I have a simple problem that I do not understand properly… I want to generate a row of houses. Therefore I add a number of static mesh components and offset them by their size (multiplied with their number index).
In order to get more variation I want to have the individual assets scaled by a random factor.
The first image shows how I set up my BluePrint. It just generates a random number (in stream) and uses this for scaling each mesh. Then it is supposed to take the very same number for scaling the offset (default house size = 1024). However, as you can see in the second/third image that does not work. If I do not scale anything the houses are aligned nicely. But if the scaling is applied the houses appear in different sizes (nice!) but apparently a different value is used for offsetting their position, so that they come out at seemingly random positions (which is not nice!).
I also tried promoting the random number to a variable and using this for scaling and offsetting but it didn’t work either…

Any suggestion what Iam doing wrong?

Best regards,

If you are going to be giving them random scale then you should use “get component bounds” after setting the scale. The “box extent” will be the width, height, depth. Divide width by 2 and use that + half the width of the next building as the offset for the next building. (Assuming your pivot point is in the center of the meshes)

Great - thanks a lot!
Iam going to test this today evening :slight_smile: Argh, now it sounds that easy that Iam biting my *ss that I didn’t think of something similar^^