public static Action callback;
public static IEnumerator WaitIns { get { return WaitInstance(); } }
private static WaitUntil wait = new WaitUntil(MonoBaseObserveManageListener);
[Obsolete]
public static void AddWaitInstanceCallback(Action act)
{
callback += act;
}
[Obsolete]
public static void RemoveWaitInstanceCallback(Action act)
{
callback -= act;
}
public static IEnumerator WaitInstance()
{
yield return wait;
if (callback != null)
callback();
}
private static bool MonoBaseObserveManageListener()
{
return MonoBaseObserveManager.Instance != null;
}