Streams not working in structs or arrays

I have just been converting a simplish blueprint to be modular but have hit a bug or something; streams don’t work when in structs nor arrays, or at least, none of the ‘get random *** from stream’ do.

Hi WarLord,

Which version of the editor are you currently using? Also, could you provide a couple screenshots showing your setup?

Hi WarLord,

We haven’t heard back from you in a few days, so we are marking this post as resolved for tracking purposes. If you’re still experiencing this issue, please feel free to post back here with additional information I requested above.

Cheers,

TJ

Sorry for not replying. but you should be able to reproduce this issue if you make an array variable of random streams, get the first one (in the construction script) and using it for anything; it won’t work.

I attempted to repro this in 4.7.2 but so far I haven’t been able too. Which version are you using? Also, could you post a screenshot of your setup to make sure we are doing this the same way?

I am also using 4.7.2 and this is my setup

http://i.imgur.com/j2kFY2X.jpg

What behavior are you seeing in the editor? Is the object not rotating at all or is it rotating initially and then doesn’t rotate again?

It rotates initially (always to the same rotation no matter what however) and then does not change rotation later.

In the setup that you are using, that is the intended behavior. You’re creating an array of Streams but then you are only calling the Stream at the ‘0 Element’ over and over again.

Here is how Random Streams work. When one is first created, the random stream will generate a random rotation (or whatever type you are using), then if that same stream (seed) is ever called again it will always return the same rotation.

I’m not sure if you are familiar with Minecraft but it is similar to the way world seeds work. When a seed is created, a random world is procedurally generated from it. That seed number can then be used again to recreate the exact same world.

From the docs:

“where you want a random effect, but also a consistent distribution each time the graph is evaluated.”

Please take a look at the Random Stream documentation for more info.

Cheers,

TJ

Yes I understand how they work, it’s just they they aren’t when not straight variables, ie. If I create a standard variable of a random stream and change it in the level after placing one of the blueprints, it works and the rotation will change depending on what the random stream’s value is, but when they are in any sub sort of class, like an array, they don’t return any value other than what appears to be 0.
Thanks

Sorry about that WarLoad, I misunderstood the issue. I was able to reproduce this behavior in 4.7.3 and our latest internal build. I have entered it as JIRA UE-12223 and our developers will be investigating the issue further. We will post back here with updates as we have them.

Cheers,

TJ

Ok, thankyou :slight_smile: