예제 #1
0
        public DebugVar[] GetMembers(string[] categories)
        {
            List <string>   aux    = new(categories);
            List <DebugVar> result = new();


            var debugPages = ReflectionExtend.CreateDerivedInstances <DebugScreenVarsNative>();

            foreach (var debugPage in debugPages)
            {
                var methods = ReflectionExtend.GetMethodsWithSpecificAttribute <DebugScreenAttribute>(ArrayExtend.CreateArray(debugPage), (DebugScreenAttribute attr) =>
                {
                    return(aux != null && aux.Contains(attr.DebugCategory));
                });

                foreach (var method in methods)
                {
                    var    member = method.Invoke <MemberComplexInfo>();
                    string name   = "";
                    if (member != null)
                    {
                        name = ReflectionExtend.GetValueAttribute(method.methodInfo, (DebugScreenAttribute attr) =>
                        {
                            return(attr.DebugName);
                        });


                        result.Add(new DebugVar(name, member));
                    }
                }
            }

            return(result.ToArray());
        }
예제 #2
0
 public static void LoadString(string NameStoredVar, string value, MemberComplexInfo memberInfo)
 {
     if (NameStoredVar != null)
     {
         string result = PlayerPrefs.GetString(NameStoredVar, value);
         ReflectionExtend.SetValue(memberInfo, result);
     }
 }
예제 #3
0
 public static void LoadBool(string NameStoredVar, bool value, MemberComplexInfo memberInfo)
 {
     if (NameStoredVar != null)
     {
         bool result = GetBool(NameStoredVar, value);
         ReflectionExtend.SetValue(memberInfo, result);
     }
 }
예제 #4
0
 public static void LoadFloat(string NameStoredVar, float value, MemberComplexInfo memberInfo)
 {
     if (NameStoredVar != null)
     {
         float result = PlayerPrefs.GetFloat(NameStoredVar, value);
         ReflectionExtend.SetValue(memberInfo, result);
     }
 }
예제 #5
0
        protected override void Awake()
        {
            base.Awake();

            if (useFiller && textFillerType != null)
            {
                _filler = ReflectionExtend.CreateInstance <Filler <string> >(textFillerType);
            }
        }
예제 #6
0
        protected override void Awake()
        {
            base.Awake();

            if (useFiller && imageFillerType != null)
            {
                _filler = ReflectionExtend.CreateInstance <Filler <ImageElementInfo> >(imageFillerType);
            }
        }
예제 #7
0
 public MemberComplexInfo TimerLActiveLenght()
 {
     return(ReflectionExtend.GetValueInfo <TimerContainer>("_timersPool", "Actives", "Count"));
 }
예제 #8
0
 public MemberComplexInfo TweenLActiveLenght()
 {
     return(ReflectionExtend.GetValueInfo <TweenContainer>("_containerPool", "Actives", "Count"));
 }