Hi,
I’ve been racking my brains for days and hoping somebody might be able to point me in the right direction.
I’m trying to build a winding downhill road for my skateboarding game using a custom blueprint spline.
The spline has functionality so that I can see the track point numbers at runtime, add or remove barriers which makes building the track and playtesting very easy, and the road will always be a more or less constant downhill track.
The problem is, I would like to design the track and then build the landscape / level around it, and i’m struggling to find a workable solution.
I have tried:
-
Building a landscape (Gaea and by hand) and then using my blueprint spline with minor sculpting edits to get the edge of the road to line up with the landscape. This is a nightmare as the landscape constantly overlaps with the road, or there are gaps between the road and the landscape causing the character to fall through when rolling off the road.
-
Using landscape splines with my road mesh added on. This way I lose functionality of my blueprint spline and there are issues with the road collisions.
-
Attempted to use the “editor apply spline” node: Editor Apply Spline | Unreal Engine Documentation
However i’m not sure how to make it work. Searching on the forums yields no results and google just points people to it without explaining how to use.
I cannot reference the landscape from the SplineBP.
If I use an interface to pass the spline component to the level BP, where I can reference the landscape I can only initiate the function at runtime and it does nothing. The level BP has no construction script.
So, is there a better way to achieve this? Creating long winding mountain roads using a custom spline BP where I build the road and the level round it after?
Maybe I’m looking at this all wrong. how would you approach this?