Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple ArrayPoolsSettings
#1
I have changed my project to do Additive loading of scenes. The 'Base' scene has no references to any Curvy classes in it. But when I additively load to the 'Base' scene another scene that uses CurvySpline, I now get the message: [Curvy] More than one instance of 'Array Pools Settings' detected. You should keep only one instance of this script. 

In the debugger I see that ArrayPoolsSetting.Awake is being called for both the 'Base' scene and the scene added to it later.
How do I prevent this from happening?
Reply
#2
Hi
Does the Base scene have the _CurvyGlobal_ game object? I couldn't reproduce the issue when base scene does not have it.

PS: unrelated to this thread: please check my answer to your previous thread if that is not the case already.
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
(11-10-2022, 09:09 AM)_Aka_ Wrote: Hi
Does the Base scene have the _CurvyGlobal_ game object? I couldn't reproduce the issue when base scene does not have it.

PS: unrelated to this thread: please check my answer to your previous thread if that is not the case already.

I was able to reproduce the bug with a fresh project. See attached project.

1) Start with a clean project and a new 'BaseScene'
2) Put in a UI element that lets you load another scene 'Added' when the button is press
3) Add a Curvy Spline to the Added scene
4) Add both scenes to build
5) Run... Trigger loading of Added scene.   NO WARNING
6) Edit 'BaseScene' to add a Curvy Spline
7) Run... Trigger loading of Added scene.    WARNING correctly now occurs
8) Delete Curvy Spline from 'BaseScene'
9) Run... Trigger loading of Added scene.    WARNING still INCORRECTLY occurs.

If you search the 'BaseScene' file, you will find two references to Curvy including _CurvyGlobal.
I don't know how precisely manually edit the scene file to get rid of these without breaking the scene. Suggestions on how to get rid of the reference? Recreating my BaseScene file from scratch is not an option as it may break other things.


On the other thread... I have not tried your suggestions as I had to make progress on other areas first. I'll come back and give the items a try in the next few days.

Thanks


Attached Files
.zip   AdditiveTest.zip (Size: 29.47 KB / Downloads: 1)
Reply
#4
Hi

The _CurvyGlobal_ is automatically added to scenes when a curvy spline (and other curvy components) are created in the scene. _CurvyGlobal_ contains components that are meant to be used by multiple other curvy spline components. For example, pools of objects and connections between splines. If you don't have any curvy object in a specific scene, you can safely delete _CurvyGlobal_ from it.

So to summarize: delete _CurvyGlobal_ from BaseScene, this will get rid of the warning.

Let me know if this didn't work.
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
(11-14-2022, 09:53 AM)_Aka_ Wrote: Hi

The _CurvyGlobal_ is automatically added to scenes when a curvy spline (and other curvy components) are created in the scene. _CurvyGlobal_ contains components that are meant to be used by multiple other curvy spline components. For example, pools of objects and connections between splines. If you don't have any curvy object in a specific scene, you can safely delete _CurvyGlobal_ from it.

So to summarize: delete _CurvyGlobal_ from BaseScene, this will get rid of the warning.

Let me know if this didn't work.
Have a nice day

This I understood. My question should be "Is there a way to delete _CurvyGlobal besides manually editing the text of my BaseScene file?" 
I don't see it in the Unity visual interface anywhere.
Reply
#6
_CurvyGlobal_ should be visible in the hierarchy, usually at the bottom. If you don't see it, I think of two explanations:
1- You set to true the "Hide _CurvyGlobal_" preference in Curvy's preferences
2- You looked for the object in Play Mode, and didn't check the DontDestroyOnLoad section of the hierarchy
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
(11-15-2022, 08:50 AM)_Aka_ Wrote: _CurvyGlobal_ should be visible in the hierarchy, usually at the bottom. If you don't see it, I think of two explanations:
1- You set to true the "Hide _CurvyGlobal_" preference in Curvy's preferences
2- You looked for the object in Play Mode, and didn't check the DontDestroyOnLoad section of the hierarchy

It was marked hidden in Curvy's preferences. I toggled it; it showed up when I next entered Play mode; it stayed after exiting play mode; then I would delete it. I no longer get the warning.

Excellent. Thanks.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Distance travelled across multiple splines jh092 1 7 02-23-2024, 09:44 AM
Last Post: _Aka_
  Multiple Splines and Generators Performantly for Road System drock 1 6 07-17-2023, 10:31 AM
Last Post: _Aka_
  Warning about multiple Array Pools Settings nkornek 4 19 03-23-2023, 12:34 PM
Last Post: TurboManny
  Multiple Mesh Extrude Generator bakin 1 10 09-17-2022, 12:40 PM
Last Post: _Aka_

Forum Jump: