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.
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.