예제 #1
0
 protected void Awake()
 {
     if (_instance != null)
     {
         throw new Exception("Tentative de création d'une autre instance de BudgetPanelManager alors que c'est un singleton.");
     }
     _instance = this;
     TweenerLead.Instance.NewTween(GetComponent <RectTransform>(), tweener);
     Events.Instance.AddListener <OnPopupBuilding>(Open);
     gameObject.SetActive(false);
 }
예제 #2
0
 protected void OnDestroy()
 {
     Events.Instance.RemoveListener <OnPopupBuilding>(Open);
     _instance = null;
 }