We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 719d984 commit c7dd142Copy full SHA for c7dd142
Runtime/Pool.cs
@@ -28,6 +28,7 @@ public Pool(GameObject prefab, int count)
28
if (_prefab == null)
29
{
30
_prefab = Object.Instantiate(prefab).AddComponent<Poolable>();
31
+ UnityEngine.Object.DontDestroyOnLoad(_prefab);
32
_prefab.gameObject.SetActive(false);
33
}
34
0 commit comments