using UnityEngine; public class MonoBehaviourSingletonTemplate : MyCoroutine where T : MyCoroutine { public static T Ins; protected virtual void Awake() { Ins = this as T; } protected void DontDestroy() { DontDestroyOnLoad(gameObject); } } public class MonoBehaviourSingletonTemplateBackKeyAdd : BackKeyAdd where T : MonoBehaviour { public static T Ins; protected override void Awake() { Ins = this as T; } protected void DontDestroy() { DontDestroyOnLoad(gameObject); } } public class MonoBehaviourSingletonTemplateScrollView : uScrollViewMgr where T : MonoBehaviour { public static T Ins; protected override void Awake() { Ins = this as T; Init(); } protected void DontDestroy() { DontDestroyOnLoad(gameObject); } }