Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Make connection between 2 control points
#1
Hi,  
 So If I've already got a spline with say 3 control points, then I want to connect a 2nd spline to the first but between the 2nd and 3rd control point ( CP0001 & CP0002 ) 
how could I do that please.

Regards
Reply
#2
Hi,
You can connect control points only at control points. So in your case, you will have to create a control point at the desired position and then make the connection at that level.
Did this help?
Also, the Shift and Subdivide tools in the toolbar might help in your task
Have a nice day
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply
#3
Hi. I just wondered if there was a built in way if doing that.
As what i want to achieve will be at runtime what i could do is store the info of each control point then redraw the spline but adding the new connection control point at the appropriate place, ie if between cp 1 and 2 the new control point would become cp0002 then all subsequent control points would be one number higher it'd that makes sense.
Reply
#4
Hi,
The Subdivide tool is the built-in way but it will add the new CP halfway in between the existing two CPs.
The Shift tool is the built-in way to move a CP on the spline between its neighboring CPs
Other than this, you will have to use the API to do what you described
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply
#5
Hi again, I've almost achieved what I want to achieve. Hopefully just one more question :
If I want to add a connection to say CP0003 and I've got 7 control points ( so I cant use last visible control point ) how could I do that ?

Cheers
Reply
#6
Hi,
You can access the third cp like this
yourSpline.ControlPointsList[3]
CurvyConnection is the class for creating connections
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply
#7
thanks
Reply
#8
You are welcome
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Mesh problem in generator after rotating control points ATHellboy 1 81 02-10-2020, 11:24 AM
Last Post: _Aka_
  Sync orientation at connection points (Dynamic)) ATHellboy 1 79 02-05-2020, 09:47 PM
Last Post: _Aka_
  Wheel control at the car xcube 10 3,701 01-30-2020, 07:07 PM
Last Post: xcube
  Reversing over Connection CP from Junction Rei11 5 354 01-12-2020, 07:51 PM
Last Post: Rei11

Forum Jump: