Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Parallel Splines
#5
(01-28-2020, 09:44 AM)_Aka_ Wrote: Hi,
I will answer first about having multiple lanes:
  • Your solution (the offset) is good in mhy opinion as long as it gives you the desired result
  • A solution similar to yours would have been to use the already existing Offset feature instead of coding yours
  • Before explaining the next solution, you should make the distinction between the usage of the words Spline and Path in the context of Curvy: A spline is what contains the control points. Once the spline is rasterized to be used in a Curvy Generator, it becomes a path. This process happens in the Input Spline Path module
    So, based on this, my first to go solution would have been to use the Path Relative Translation module to translate paths, and use a Path Controller instead of a Spline Controller to move your objects

About Offset feature how can it be same as mine ? Because I try to use it but no success. It is good on Y axis but by changing Offset Angle I don't find good angle for changing in X axis.

I didn't understand why I should use Path Relative Translation ? As I see it just translate the mesh.

(01-28-2020, 09:54 AM)_Aka_ Wrote: Now about switching between lanes:
  • First of all, know that there is a SwitchTo method in spline controller that does (from my understanding) the same thing that your code, with the exception that it need two different splines to switch between.
  • I think what i would have done, is to consider each road as a different spline, and lanes inside each road as different offsets, then use the SwitchTo and Offset features of the Spline Controller to navigate between different roads/lanes

I think I did the same thing. There are 2 roads, one is a main one another is the one at the right side of the main one which has 2 connection with the main one. Then at the connection points I check that ControlPointMetaData to see what offsets are supported by that control point and according to the current player offset I change spline. (I tried to use SwtichTo but it was confusing for me so I decided to change the spline directly). Do you think it is same as you ?
Reply


Messages In This Thread
Parallel Splines - by ATHellboy - 01-25-2020, 10:25 AM
RE: Parallel Splines - by ATHellboy - 01-25-2020, 02:34 PM
RE: Parallel Splines - by _Aka_ - 01-28-2020, 09:44 AM
RE: Parallel Splines - by ATHellboy - 01-28-2020, 10:43 AM
RE: Parallel Splines - by _Aka_ - 01-28-2020, 03:36 PM
RE: Parallel Splines - by _Aka_ - 01-28-2020, 09:54 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Help with procedural roads and splines ramiroflores 1 3 11 hours ago
Last Post: _Aka_
Information New free asset: Converter For Unity Splines _Aka_ 5 19 04-25-2024, 11:11 AM
Last Post: _Aka_
  snap to the curve created by the curvy splines segment points ShiroeYamamoto 3 11 04-02-2024, 02:24 PM
Last Post: _Aka_
Bug Changing spline connection in inspector causes splines to revert to defaults lacota 3 6 03-18-2024, 07:55 PM
Last Post: _Aka_

Forum Jump: