Exemplo n.º 1
0
 static internal void Register <T, Y, U, I>(string key, OLiOEvent <T, Y, U, I> e)
 {
     if (UEventsStringDictionary <T, Y, U, I> .Instance.dic_StringOLiOEventTYUI.ContainsKey(key))
     {
         UEventsStringDictionary <T, Y, U, I> .Instance.dic_StringOLiOEventTYUI[key] = e;
     }
     else
     {
         UEventsStringDictionary <T, Y, U, I> .Instance.dic_StringOLiOEventTYUI.Add(key, e);
     }
 }
Exemplo n.º 2
0
 static internal void Register(string key, OLiOEvent e)
 {
     if (UEventsStringDictionary.Instance.dic_StringOLiOEvent.ContainsKey(key))
     {
         UEventsStringDictionary.Instance.dic_StringOLiOEvent[key] = e;
     }
     else
     {
         UEventsStringDictionary.Instance.dic_StringOLiOEvent.Add(key, e);
     }
 }
Exemplo n.º 3
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <typeparam name="T">无返回值委托的参数T</typeparam>
 /// <typeparam name="Y">无返回值委托的参数Y</typeparam>
 /// <typeparam name="U">无返回值委托的参数U</typeparam>
 /// <typeparam name="I">无返回值委托的参数I</typeparam>
 /// <param name="eventTYUI">UEvent</param>
 /// <param name="key">键</param>
 public void PutUEventInVoidDic <T, Y, U, I>(OLiOEvent <T, Y, U, I> @eventTYUI, string key)
 {
     @eventTYUI.PutInDic <T, Y, U, I>(key);
 }
Exemplo n.º 4
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <param name="event">UEvent</param>
 /// <param name="key">返回键</param>
 public void PutUEventInVoidDic <T, Y, U, I>(OLiOEvent <T, Y, U, I> @event, out string key)
 {
     key = string.Format("{0}{1}", defaultKey, nameof(OLiOEvent <T, Y, U, I>), KeyForXY(UnityEngine.Random.Range(1, 20), UnityEngine.Random.Range(1, 99)));
     @event.PutInDic(key);
 }
Exemplo n.º 5
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <typeparam name="T">无返回值委托的参数T</typeparam>
 /// <typeparam name="Y">无返回值委托的参数Y</typeparam>
 /// <typeparam name="U">无返回值委托的参数U</typeparam>
 /// <param name="eventTYU">UEvent</param>
 /// <param name="key">键</param>
 public void PutUEventInVoidDic <T, Y, U>(OLiOEvent <T, Y, U> @eventTYU, string key)
 {
     @eventTYU.PutInDic <T, Y, U>(key);
 }
Exemplo n.º 6
0
        /// <summary>
        /// UEvent数据写入无返回值字典
        /// </summary>
        /// <typeparam name="T">无返回值委托的参数T</typeparam>
        /// <typeparam name="Y">无返回值委托的参数Y</typeparam>
        /// <typeparam name="U">无返回值委托的参数U</typeparam>
        /// <param name="eventTYU">UEvent</param>
        public void PutUEventInVoidDic <T, Y, U>(OLiOEvent <T, Y, U> @eventTYU)
        {
            string key = string.Format("{0}{1}", defaultKey, nameof(OLiOEvent <T, Y, U>), KeyForXY(UnityEngine.Random.Range(1, 20), UnityEngine.Random.Range(1, 99)));

            PutUEventInVoidDic(@eventTYU, key);
        }
Exemplo n.º 7
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <typeparam name="T">无返回值委托的参数T</typeparam>
 /// <typeparam name="Y">无返回值委托的参数Y</typeparam>
 /// <param name="eventTY">UEvent</param>
 /// <param name="key">键</param>
 public void PutUEventInVoidDic <T, Y>(OLiOEvent <T, Y> @eventTY, string key)
 {
     @eventTY.PutInDic <T, Y>(key);
 }
Exemplo n.º 8
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <typeparam name="T">无返回值委托的参数T</typeparam>
 /// <param name="event">UEvent</param>
 /// <param name="key">键</param>
 public void PutUEventInVoidDic <T>(OLiOEvent <T> @event, string key)
 {
     @event.PutInDic <T>(key);
 }
Exemplo n.º 9
0
 /// <summary>
 /// UEvent数据写入无返回值字典
 /// </summary>
 /// <param name="event">UEvent</param>
 /// <param name="key">键</param>
 public void PutUEventInVoidDic(OLiOEvent @event, string key)
 {
     @event.PutInDic(key);
 }
 static internal void PutInDic <T, Y, U, I>(this OLiOEvent <T, Y, U, I> @event, string key)
 {
     UEventsStringTriggers.Register <T, Y, U, I>(key, @event);
 }
 static internal void PutInDic(this OLiOEvent @event, string key)
 {
     UEventsStringTriggers.Register(key, @event);
 }