Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Issue Curvy 2.0.2 in an EXE Build
#1
I'm using the latest version of Curvy with Unity 5.2.1f1 (free).

I can get curvy to work fine while in the development environment, but when I want curvy to work in a demo build as an EXE, the curve doesn't appear.  Since I go directly to a build from a working version, I'm not sure what to look for to resolve this problem; is it an issue with Curvy?  The picture below describes the situation (note: that the yellow block placement and the curvy curve are all randomly generated). 

Either the curve doesn't generate or the control points don't get refreshed when I call "Spline.Refresh()".  Any ideas?

[Image: 36a1a26584.jpg]
Reply
#2
The only difference to the editor is that in the editor the curve refreshes at more occasions (i.e. ControlPoints use Update() in the editor, but not automatically at runtime for performance reasons). When dynamically working with curves at runtime, there are a few basic rules:

* If you work with an existing spline at startup, be sure to check/wait for initialization ("while (!spline.IsInitialized) yield 0" in Start())
* If you change any spline parameters or add/remove Control Points, the spline is updated either in it's next call to Update() (next frame usually) or if you call spline.Refresh() manually
* If you change the position if Control Points, the spline needs to know about this. Three options:
   - use API to move the CP (CurvySplineSegment.localPosition etc...)
   - enable "Check Transforms" at the spline to automatically detect changed CP transforms
   - call CurvySplineSegment.SetDirty() manually

For the latter case, note that calling Refresh() only doesn't help because it only recalculates changed stuff, so you need to call SetDirty() before to make the spline know about changes.

If that doesn't help, please post your generation code.
Reply
#3
Thanks Jake ... "CurvySplineSegment.SetDirty()" resolved my issue.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Curvy Line Renderer for UI Spline? gekido 5 13 10-29-2024, 10:19 AM
Last Post: _Aka_
  Invisible Gizmos In Latest Curvy Splines orrenravid1 1 5 06-11-2024, 07:36 AM
Last Post: _Aka_
  Rasterized Path Range issue proton 7 27 04-30-2024, 11:17 AM
Last Post: _Aka_
  8.8.0 is live, and it improves Curvy Generator greatly _Aka_ 1 13 04-03-2024, 03:16 PM
Last Post: _Aka_

Forum Jump: