No announcement yet.

[Spline RunTime] Can't add spline point on realtime

  • Filter
  • Time
  • Show
Clear All
new posts

    [Spline RunTime] Can't add spline point on realtime

    Hello everyone ! I'm a french video game student and i have some issues with how to set up start and end point of a spline by adding more points in realtime. I hope you will be able to help me understand the logic behind my problems.

    In a 3D platformer you control a character who can spawn clouds and use them. I would like to make a rain cloud who can draw water on the map by using a spline in realtime.
    When you use the ability, the third person character is unposses. You now posses the cloud. You can move the cloud, the cloud is a pawn.
    Click image for larger version

Name:	2016-05-08_17h40_10.png
Views:	1
Size:	447.9 KB
ID:	1181876
    A line trace check the impact point to spawn a spline actor while the rain cloud is active (a spline component and a static mesh or spline mesh)
    After the spline actor is spawned i want a new spline point be added every X tick. In order to create a water path.
    Click image for larger version

Name:	2016-05-08_18h06_11.png
Views:	1
Size:	311.2 KB
ID:	1181881
    It's the same spline as in this excellent tutorial video

    [PROBLEM 1 ]
    the spline points that i add dont seems to be add or recognize by the start point of the primary spline actor.

    [PROBLEM 2 ]
    I miss some logic concerning where the add spline point node must be placed.
    At best the spline actor is spawned multiple times with no links between them.

    Spawned spline actor Event graph Blueprint
    Click image for larger version

Name:	2016-05-08_17h41_35.png
Views:	1
Size:	235.7 KB
ID:	1181877

    Spawned spline actor Construction Script
    Click image for larger version

Name:	2016-05-08_17h42_12.png
Views:	1
Size:	363.1 KB
ID:	1181878

    Rain Cloud Pawn Event Graph
    Click image for larger version

Name:	2016-05-08_17h43_22.png
Views:	1
Size:	368.5 KB
ID:	1181879
    Click image for larger version

Name:	2016-05-08_17h44_04.png
Views:	1
Size:	314.8 KB
ID:	1181880

    Every components are set as movable.
    The spline works perfectly in editor. (rotation, tangent calcul, spacing, new points adaptation)
    But not in realtime ... T_T

    I'll be happy to discuss about possibilities of adding new spline points of a spline actor in realtime.
    Thank you so much !

    i have the exact same problem, cant add points at runtime,
    did you solved it ?


      Got it working, i was placing the same point over and over so the idea is to get the latest spline point and get its location+(direction*someScale) to generate the next point (like interpolation) then you will want to also add the tangent of the previous point to the "in tangent" of the next point