Esempio n. 1
0
        private static TweenValue GenTween(float duration, LuaInterface.LuaFunction func, int param)
        {
            int index = -1;

            if (idles.Count > 0)
            {
                index = idles.Dequeue();
            }

            if (index < 0)
            {
                index = pool.Count;
                Info info = new Info(index);
                pool.Add(info);
            }

            Info cur = pool[index];

            cur.func      = func;
            cur.funcParam = param;
            cur.SetActive(true);

            TweenValue tween = TweenValue.Begin <TweenValue>(cur.go, duration);

            tween.SetDelegateFunc(cur.TweenCallFunc);
            return(tween);
        }
Esempio n. 2
0
        public static void GenEaseInTween(float duration, LuaInterface.LuaFunction func, int param)
        {
            TweenValue tween = GenTween(duration, func, param);

            tween.method = UITweener.Method.EaseIn;
        }