Пример #1
0
        public void StopListening(UIEvents.Type eventName, Action <string> listener)
        {
            if (eventDictionary == null)
            {
                Init();
            }

            Action <string> thisEvent = null;

            if (eventDictionary.ContainsKey(eventName))
            {
                thisEvent  = eventDictionary[eventName];
                thisEvent -= listener;
            }
        }
Пример #2
0
        public void TriggerEvent(UIEvents.Type eventName, string message = "")
        {
            if (eventDictionary == null)
            {
                Init();
            }

            Action <string> thisEvent = null;

            if (eventDictionary.ContainsKey(eventName))
            {
                thisEvent = eventDictionary[eventName];
                thisEvent(message);
            }
        }
Пример #3
0
 protected void StartListenting(UIEvents.Type type, System.Action <string> listener)
 {
     _HUD.StartListening(type, listener);
 }
Пример #4
0
 protected void TriggerHUDEvent(UIEvents.Type type, string message = "")
 {
     _HUD.TriggerEvent(type, message);
 }
Пример #5
0
 public void ListenForHUDEvent(UIEvents.Type type, System.Action <string> listen)
 {
     _HUD.StartListening(type, listen);
 }
Пример #6
0
 /// <summary>
 /// Trigger a main menu ui event
 /// </summary>
 /// <param name="type"></param>
 protected void TriggerEvent(UIEvents.Type type, string message = "")
 {
     _Observer.TriggerEvent(type, message);
 }
Пример #7
0
 public void TriggerUIEvent(UIEvents.Type type)
 {
     _MainMenuObserver.TriggerEvent(type);
 }