Hi,
I’ve created a procedural stair blueprint that adds more treads the more you stretch it out. The issue is though that when I use it the FPS drops dramatically.
I have narrowed it down to the treads that are causing the issue but I have no idea why.
I have tested with 17 treads on a stair and the fps is sitting at about 28. When I removed the treads the fps goes up to 57.
The mesh of the tread is a box made in 3ds Max (12 triangles) and I unwrapped the uv and then exported the FBX and put a very basic material on it (one colour) in UE4.
Further to the above, here is the blueprint of the tread inserting.
I can provide more of the blueprint but it is basically the same repeated with different components.
I worked out what the problem was!
I had more components spawning in to the right (hand rails, posts, etc) on the above screen shot of the blueprint. All I did was plug it to the completed node on the ForLoop and that immediately improved the fps.
Not sure why this worked seeing as the construction script i thought only ran once when something changed and not continually. I guess it kept calculating everything even though nothing was changing.
Hope this helps someone else if they are having a similar problem with ForLoops.