コード例 #1
0
    static int Play(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 1)
            {
                BCTweenNumText obj = (BCTweenNumText)ToLua.CheckObject <BCTweenNumText>(L, 1);
                obj.Play();
                return(0);
            }
            else if (count == 2)
            {
                BCTweenNumText obj  = (BCTweenNumText)ToLua.CheckObject <BCTweenNumText>(L, 1);
                bool           arg0 = LuaDLL.luaL_checkboolean(L, 2);
                obj.Play(arg0);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: BCTweenNumText.Play"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }
コード例 #2
0
 static int SetEndToCurrentValue(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         BCTweenNumText obj = (BCTweenNumText)ToLua.CheckObject <BCTweenNumText>(L, 1);
         obj.SetEndToCurrentValue();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
コード例 #3
0
    /// <summary>
    /// Start the tweening operation.
    /// </summary>

    static public BCTweenNumText Begin(GameObject go, float duration, int Num)
    {
        BCTweenNumText comp = BCUITweener.Begin <BCTweenNumText>(go, duration);

        comp.from = comp.value;
        comp.to   = Num;

        if (duration <= 0f)
        {
            comp.Sample(1f, true);
            comp.enabled = false;
        }
        return(comp);
    }
コード例 #4
0
    static int set_value(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText obj  = (BCTweenNumText)o;
            int            arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
            obj.value = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index value on a nil value"));
        }
    }
コード例 #5
0
    static int set_insertChar(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText            obj  = (BCTweenNumText)o;
            BCTweenNumText.InsertChar arg0 = (BCTweenNumText.InsertChar)ToLua.CheckObject(L, 2, typeof(BCTweenNumText.InsertChar));
            obj.insertChar = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index insertChar on a nil value"));
        }
    }
コード例 #6
0
    static int set_nFenWei(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText        obj  = (BCTweenNumText)o;
            BCTweenNumText.FenWei arg0 = (BCTweenNumText.FenWei)ToLua.CheckObject(L, 2, typeof(BCTweenNumText.FenWei));
            obj.nFenWei = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index nFenWei on a nil value"));
        }
    }
コード例 #7
0
    static int set_sound(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText          obj  = (BCTweenNumText)o;
            UnityEngine.AudioSource arg0 = (UnityEngine.AudioSource)ToLua.CheckObject(L, 2, typeof(UnityEngine.AudioSource));
            obj.sound = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index sound on a nil value"));
        }
    }
コード例 #8
0
    static int set_uguiText(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText      obj  = (BCTweenNumText)o;
            UnityEngine.UI.Text arg0 = (UnityEngine.UI.Text)ToLua.CheckObject <UnityEngine.UI.Text>(L, 2);
            obj.uguiText = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index uguiText on a nil value"));
        }
    }
コード例 #9
0
    static int get_value(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText obj = (BCTweenNumText)o;
            int            ret = obj.value;
            LuaDLL.lua_pushinteger(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index value on a nil value"));
        }
    }
コード例 #10
0
 static int Begin(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 3);
         UnityEngine.GameObject arg0 = (UnityEngine.GameObject)ToLua.CheckObject(L, 1, typeof(UnityEngine.GameObject));
         float          arg1         = (float)LuaDLL.luaL_checknumber(L, 2);
         int            arg2         = (int)LuaDLL.luaL_checknumber(L, 3);
         BCTweenNumText o            = BCTweenNumText.Begin(arg0, arg1, arg2);
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
コード例 #11
0
    static int get_insertChar(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText            obj = (BCTweenNumText)o;
            BCTweenNumText.InsertChar ret = obj.insertChar;
            ToLua.Push(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index insertChar on a nil value"));
        }
    }
コード例 #12
0
    static int get_nFenWei(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText        obj = (BCTweenNumText)o;
            BCTweenNumText.FenWei ret = obj.nFenWei;
            ToLua.Push(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index nFenWei on a nil value"));
        }
    }
コード例 #13
0
    static int get_soundStartTime(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText obj = (BCTweenNumText)o;
            float          ret = obj.soundStartTime;
            LuaDLL.lua_pushnumber(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index soundStartTime on a nil value"));
        }
    }
コード例 #14
0
    static int get_sound(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText          obj = (BCTweenNumText)o;
            UnityEngine.AudioSource ret = obj.sound;
            ToLua.PushSealed(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index sound on a nil value"));
        }
    }
コード例 #15
0
    static int get_uguiText(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            BCTweenNumText      obj = (BCTweenNumText)o;
            UnityEngine.UI.Text ret = obj.uguiText;
            ToLua.Push(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o, "attempt to index uguiText on a nil value"));
        }
    }
コード例 #16
0
    public override void OnInspectorGUI()
    {
        GUILayout.Space(6f);
        BCEditorTools.SetLabelWidth(120f);

        BCTweenNumText tw = target as BCTweenNumText;

        DrawDefaultInspector();
        if (tw.soundStartTime < 0)
        {
            tw.soundStartTime = 0;
        }
        if (tw.soundSkipCount < 0)
        {
            tw.soundStartTime = 0;
        }
        DrawCommonProperties();
    }