Beispiel #1
0
        public static T AddConment <T>() where T : EZMonoBehaviour, new()
        {
            var key = typeof(T).ToString();

            if (!Lifecycles.ContainsKey(key))
            {
                var value = (T)Activator.CreateInstance(typeof(T));
                Lifecycles.Add(key, value);
                Keys.Add(key);
                return(value);
            }
            return(default);