SplineMeshComponent collision not working at runtime?
I installed UE4 two days ago and have been messing around with trying to procedurally create a track to traverse in a vehicle (building off the basic vehicle template). I've created a basic blueprint for a spline component which adds an appropriate number of SplineMeshComponents based on the amount of points on the spline. Using the event graph, I've then added functionality to extend the spline in the Y direction every time a key is pressed (F). Collision works fine for the initial points created in the editor, but collision does not seem to be enabled/working for anything created at runtime and I'm unsure of why. Here is an example using simulation mode and the "Player Collision" view.
The location of the car is where the spline ends after having been created in editor mode. Collision seems to be working for the length of the blue arrow. The points after the vehicle (the length of the red arrow) do not seem to be working and the vehicle simply falls to the floor past it's current point.
Here is the blueprint's current construction script.
Here is the blueprints event graph.
I've selected "Collision Preset: Block All" for the function "Add SplineMeshComponent" in both cases. Does anybody have an idea as to what I'm missing in order for this to work?
asked Jan 28 '15 at 06:40 PM in Bug Reports
Thank you for the report. I was able to reproduce this and I have entered it as JIRA UE-8565 in our tracking software. Our developers will be looking into the issue and we will post an update here as soon as we can.
Unfortunately I don't have a workaround for the issue at the moment, but I did notice what was happening. The collision is being spawned in for the mesh but it's being spawned in at the 0,0,0 location relative to the blueprint. You probably didn't notice this unless you you experiment with different sized meshes.
answered Jan 28 '15 at 10:00 PM
TJ V ♦♦ STAFF
Okay, phew, I've drilled down into the source and fixed this to my satisfaction. I'll submit a pull request to Epic and maybe save someone some time.
In the meantime, if you need this functionality, the solution is:
-Follow the instructions for downloading UE4 from github. This takes a long long while.
-Once Visual Studio opens make the changes in attached image
-Continue building the engine and the editor
Follow this question
Once you sign in you will be able to subscribe for any updates here