using UnityEngine; namespace PMaker.DependencyInjection { public class SingletonMonobehaviour : BaseBehaviour { protected virtual void Awake() { IoC.AddSingleton(this.GetType(), this); } protected virtual void OnDestroy() { IoC.RemoveSingleton(this.GetType()); } } }