22 lines
472 B
C#
22 lines
472 B
C#
|
|
using UnityEngine;
|
||
|
|
|
||
|
|
namespace Gameplay.Pool.Debug
|
||
|
|
{
|
||
|
|
public class CmpPoolManager: MonoBehaviour
|
||
|
|
{
|
||
|
|
private static CmpPoolManager _instance;
|
||
|
|
|
||
|
|
public static void CreateInstance()
|
||
|
|
{
|
||
|
|
if (_instance != null)
|
||
|
|
{
|
||
|
|
return;
|
||
|
|
}
|
||
|
|
var obj = new GameObject("PoolManager");
|
||
|
|
DontDestroyOnLoad(obj);
|
||
|
|
_instance = obj.AddComponent<CmpPoolManager>();
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|
||
|
|
}
|