Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ScanConnections() causes heavy load in play mode, even with all Curvy objects removed
#5
Hi again.

1- After digging in this subject, I see that ScanConnections is not set to be executed every frame. It is supposed to execute only when the hierarchy changes. Does your hierarchy change every frame?

2- I tested with 20k cubes, and ScanConnections did not show any significant CPU usage. Maybe it is because your game objects are way more complex?

3- Here is an optimization to ScanConnections:
replace
CurvyConnection[] o = GameObject.FindObjectsOfType<CurvyConnection>();
with
CurvyConnection[] o = CurvyGlobalManager.Instance.GetComponentsInChildren<CurvyConnection>();
Since I couldn't reproduce the issue, I wasn't able to test how efficient this optimization is, but it is theoretically efficient. Can you please apply it on your project and tell me what was the result? 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


Messages In This Thread
RE: ScanConnections() causes heavy load in play mode, even with all Curvy objects removed - by _Aka_ - 07-23-2021, 12:28 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Curvy Line Renderer for UI Spline? gekido 3 6 04-04-2024, 12:56 PM
Last Post: _Aka_
  8.8.0 is live, and it improves Curvy Generator greatly _Aka_ 1 10 04-03-2024, 03:16 PM
Last Post: _Aka_
  snap to the curve created by the curvy splines segment points ShiroeYamamoto 3 11 04-02-2024, 02:24 PM
Last Post: _Aka_
Exclamation Extending Curvy Generator for Advanced Lofting - Feasibility Check amutp 2 5 03-27-2024, 07:25 AM
Last Post: amutp

Forum Jump: