Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Spline object on a spline path
#21
1) Common ATHellboy, it's easy to find. Did you look for it before asking me? I feel that you rely too much on me. The Position of a spline controller is SplineController.Position.
The From and To fields of Shape Extrusion module is BuildShapeExtrusion.From and BuildShapeExtrusion.To.
2) The solution is to unpack the generator (unlink it from the prefab)
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply
#22
(03-01-2020, 03:12 PM)_Aka_ Wrote: 1) Common ATHellboy, it's easy to find. Did you look for it before asking me? I feel that you rely too much on me. The Position of a spline controller is SplineController.Position.
The From and To fields of Shape Extrusion module is BuildShapeExtrusion.From and BuildShapeExtrusion.To.
2) The solution is to unpack the generator (unlink it from the prefab)

1) Dude, I think you don't understand my need! I know how to access them but as you know the From and To values are not same as SplineController.Postion although they should be, because they are based on Spline. BTW you said they are not same (Although I don't know what the reason is) and I should sync them (if it means how to make them same) and because it is rely on your API I should ask for help from you.
Now you know what the problem is ?

2) I did understand this solution but it is not really a solution! I made that prefab for a reason l, to make change on all of them if we will need to so by unlinking I will  lose this functionality which is most important functionality of prefab.
Reply
#23
1) I don't see why they should be the same: there are different values for different independent features. In your game you want them to be the same, and the API allows for it, but I don't see why it should be the same for all the other users.
So, first, read this if it is not already the case, so you understand what is difference between TF (which represents a mathematical notion behind splines) and distance (which is the notion that most people think with): https://curvyeditor.com/documentation/sp...]=tf#units
then, here is the code you want:
yourShapeExtrusion.From = yourController.AbsolutePosition / yourController.Spline.Length;
I did not compile this code, so it might have a minor typo

2)That's a restriction coming from Unity's side. If I find a workaround around it I will include it the next update
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
Question Check Spline collisions (Pathfinding) Hukha 4 77 03-24-2020, 02:00 PM
Last Post: _Aka_
  Add Template problem in the Generator with Input Spline Shape prefab ATHellboy 1 105 03-13-2020, 11:27 PM
Last Post: _Aka_
  Convert position of a point on a spline to another spline which is connected ATHellboy 5 396 02-17-2020, 12:17 PM
Last Post: _Aka_
  Refresh spline doesn't seem to be working dazz777 6 978 01-22-2020, 12:55 AM
Last Post: _Aka_

Forum Jump: