PC-20230316NUNE\Administrator 894100ae37 提交Unity 联机Pro
2024-08-17 14:27:18 +08:00

18 lines
409 B
C#

namespace SRF.Service
{
public abstract class SRServiceBase<T> : SRMonoBehaviourEx where T : class
{
protected override void Awake()
{
base.Awake();
SRServiceManager.RegisterService<T>(this);
}
protected override void OnDestroy()
{
base.OnDestroy();
SRServiceManager.UnRegisterService<T>();
}
}
}