Reference spline information in one blueprint from another blueprint

I couldn’t find the solution digging through the forums, so I figured I would ask. I have 2 blueprints that I am using to build a driving rig. The first BP (bp_spline_road) is spline based road building tool used to populate meshes and deform the landscape. The second BP (bp_spline_rig) is a simple spline setup that I am using to drive animation of vehicles in Sequencer. I tried just attaching everything to the road to animate, but I need to turn on “Run Construction Script in Sequencer”, which then reruns the whole road script every frame and slows down.

My goal is to have the spline_rig spline reference the spline in the spline_road, so that wherever the road is paved the vehicles will just drive along the road when I animate it. Any thoughts on how I can reference the spline_road into spline_rig? Thanks a ton!


  • in the spline_rig actor, create a variable of the spline_road type and flag it as Instance Editable:

  • the rig can now refer to any road:


Docs:

1 Like

This helped a ton! There were a few things that I got hung up on, probably because I didn’t share enough detail. After a bit of trial and error this is what I had to change, in the event it helps anyone else out.

I ended up making a third blueprint that only had a spline in it and that was it. This served as my level spline “master” that I attached all of the other blueprint splines off of.

In my spline_rig blueprint, I removed the spline actor that I had. Next, I created a new variable > Object Type > BP Spline REF > Object Reference. I used the GET for this and swapped out any GET references that I had for the original spline actor for this new variable. Back in the details panel of the bp_spline_rig, I was finally able to set the reference to the bp_spline_REF spline. I am not sure what I was doing wrong at this step, but I could not get the drop down menu to show any splines that I had in the scene, until I made the variable refernece specific.

Since this worked, I was able to do the same variable swap for the road system and now all blueprints that use splines, will reference the bp_spline_REF in my scene. One spline to rule them all.






1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.