Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Spline Gizmos & Segments Invisible while Drawing
#15
Update: issue is fixed in the soon to be released 8.5.0.

Here is an explanation of what caused the issue:
Spline segments use Unity's OnDrawGizmos and OnDrawGizmosSelected to draw the gizmos. These methods are not called exclusively, meaning that a selected segment will have both methods called. As an optimization, I avoided drawing gizmo twice, by not drawing it in OnDrawGizmos if OnDrawGizmosSelected was going to be called. To do so, I had a code in OnDrawGizmos that predicts if OnDrawGizmosSelected is going to be called. That prediction code had different versions, since the rules of calling OnDrawGizmosSelected were different between main Unity versions. By main version I mean 20XX.Y, such as 2022.1 or 2020.3
Now even within the same main version, those rule change, as we witnessed with 2021.3.16 and 2021.3.22. There is as far as I know no way in the code to know which minor version the code is running on. And to be honest, even if there was, I would not bother, since any future minor version could break the code again. So I decided to unfortunately remove the optimization.
Thanks a lot for your patience
If and when you feel like it, please leave a review for the asset, that helps a lot
Have a great day.
Available for freelance work, feel free to reach out: toolbuddy.net
Please consider leaving a review for Curvy, this helps immensely. Thank you.
Reply


Messages In This Thread
RE: Spline Gizmos & Segments Invisible while Drawing - by _Aka_ - 04-07-2023, 04:16 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Best way to duplicate a spline with an offset Kapistijn 8 1,356 04-12-2026, 03:18 PM
Last Post: _Aka_
Smile Constant speed along a spline? tfishell 1 657 11-13-2025, 11:32 AM
Last Post: _Aka_
  SplineController Ignores Follow-Up and Chooses Wrong Spline Josenildo 7 4,457 07-29-2025, 09:15 PM
Last Post: _Aka_
  Curvy Line Renderer for UI Spline? gekido 7 6,216 07-13-2025, 07:11 PM
Last Post: _Aka_

Forum Jump: