Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
I have a question about curvySpline
#1
Hi, everyone. I want to realize the map function in Unity2D mode.
Now I have realized the level map and path by CurvyUISpline+CurvyLineRenderer.
But now I have a problem, I want to achieve when I reach the fifth level, the path in front of the level is a solid line, but the path after the fifth level is a dotted line, I do not know how to achieve, I hope you can provide a detailed idea, thank you
Reply
#2
Hi
Sorry but I am missing information to be able to help you. Can you please attach screenshots or drawings explaining what is the current situation and what is the expected behavior?
Thanks
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
(07-05-2023, 10:59 AM)_Aka_ Wrote: Hi
Sorry but I am missing information to be able to help you. Can you please attach screenshots or drawings explaining what is the current situation and what is the expected behavior?
Thanks
Thank you for your reply。
How can I use CurvyLineRenderer to achieve a line segment like the one in the picture


Attached Files Thumbnail(s)
   
Reply
#4
Hi
CurvyLineRenderer is a class that synchronises a Curvy Spline with a Unity's LineRenderer. The display is defined by the LineRenderer. So to have a dotted line with a CurvyLineRenderer, you need to configure the LineRenderer to display a dotted line. Surely you can find this information online, on Unity's forums and whatnot. I guess this is doable by setting a dotted material to the LineRenderer.
I hope this helped.
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
#5
(07-06-2023, 10:26 AM)_Aka_ Wrote: Hi
CurvyLineRenderer is a class that synchronises a Curvy Spline with a Unity's LineRenderer. The display is defined by the LineRenderer. So to have a dotted line with a CurvyLineRenderer, you need to configure the LineRenderer to display a dotted line. Surely you can find this information online, on Unity's forums and whatnot. I guess this is doable by setting a dotted material to the LineRenderer.
I hope this helped.
Have a nice day

Thank you for your reply。
Suppose I have a line segment of 10 points drawn on the screen using CurvyLineRenderer, and I want to set it dynamically at run time for example 1-4 points connected by line segment 1, 5-10 points connected by line segment 2, and after I trigger some condition become 1-5 connected by line segment 1 and 6-10 connected by line segment 2.
I now the idea is to get a point in the whole period of the percentage of the line segment, and then through curvySpline. GetPositionsCache () to get the result of multiply this percentage, then the results will be assigned to LineRenderer to draw. How do I get this percentage? Or do you have a better way to do it?
Reply
#6
There is an easier way to do it: using the Curvy Generator and its Create Path Line Renderer module. This module takes as an input a Path, which can be made from a spline while defining the start/end CPs.


Attached Files Thumbnail(s)
   
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
(07-07-2023, 12:01 PM)_Aka_ Wrote: There is an easier way to do it: using the Curvy Generator and its Create Path Line Renderer module. This module takes as an input a Path, which can be made from a spline while defining the start/end CPs.

Thank you very much。
Your method is much simpler, Big Grin Big Grin
Reply
#8
You are welcome
If and when you feel like it, please leave a review for the asset, that helps a lot.
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
#9
(07-10-2023, 10:42 AM)_Aka_ Wrote: You are welcome
If and when you feel like it, please leave a review for the asset, that helps a lot.
Have a nice day

Hi,I have a new problem Smile
When I reach the third level, I want the solid line to be slowly filled to the third level, but through the Start/End CPs dynamic setting of line segment display, the solid line is directly displayed to the third level, may I ask if there is any way to achieve the solid line to be slowly filled to the third level?
Similar to Dotween animation.


Attached Files Thumbnail(s)
   
Reply
#10
You will then have to use the Range parameter from the Rasterize Path module.
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
  Newbie Question: Uniformly increase spacing between volume spots? SAMYTHEBIGJUICY 1 5 09-01-2023, 03:38 PM
Last Post: _Aka_
  "Deadloop in CurvySPline.Refresh" spam Valkymaera 3 11 05-30-2023, 10:56 AM
Last Post: _Aka_
  Question about generator Mos Def 7 1,807 04-10-2023, 10:20 PM
Last Post: _Aka_
  Is curvyspline a good solution for a 2D rail grinding game? bazz_boyy1 2 8 03-01-2022, 11:49 AM
Last Post: _Aka_

Forum Jump: