Example #1
0
    static int HandlePriority(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 1);
        UIutils obj = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        int     o   = obj.HandlePriority();

        LuaScriptMgr.Push(L, o);
        return(1);
    }
Example #2
0
    static int LoadUiElement(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        UIutils obj  = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        string  arg0 = LuaScriptMgr.GetLuaString(L, 2);

        obj.LoadUiElement(arg0);
        return(0);
    }
Example #3
0
    static int NewUIElement(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        UIutils    obj  = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        Object     arg0 = (Object)LuaScriptMgr.GetUnityObject(L, 2, typeof(Object));
        GameObject o    = obj.NewUIElement(arg0);

        LuaScriptMgr.Push(L, o);
        return(1);
    }
Example #4
0
    static int setToogleAction(IntPtr L)
    {
        int         count = LuaDLL.lua_gettop(L);
        UIutils     obj   = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        GameObject  arg0  = (GameObject)LuaScriptMgr.GetUnityObject(L, 2, typeof(GameObject));
        LuaFunction arg1  = LuaScriptMgr.GetLuaFunction(L, 3);

        object[] objs2 = LuaScriptMgr.GetParamsObject(L, 4, count - 3);
        obj.setToogleAction(arg0, arg1, objs2);
        return(0);
    }
Example #5
0
    static int HandleEvent(IntPtr L)
    {
        int     count = LuaDLL.lua_gettop(L);
        UIutils obj   = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        int     arg0  = (int)LuaScriptMgr.GetNumber(L, 2);

        object[] objs1 = LuaScriptMgr.GetParamsObject(L, 3, count - 2);
        bool     o     = obj.HandleEvent(arg0, objs1);

        LuaScriptMgr.Push(L, o);
        return(1);
    }
Example #6
0
    static int addButtonNormalClick(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 3);
        UIutils    obj       = (UIutils)LuaScriptMgr.GetUnityObjectSelf(L, 1, "UIutils");
        GameObject arg0      = (GameObject)LuaScriptMgr.GetUnityObject(L, 2, typeof(GameObject));
        Action     arg1      = null;
        LuaTypes   funcType3 = LuaDLL.lua_type(L, 3);

        if (funcType3 != LuaTypes.LUA_TFUNCTION)
        {
            arg1 = (Action)LuaScriptMgr.GetNetObject(L, 3, typeof(Action));
        }
        else
        {
            LuaFunction func = LuaScriptMgr.GetLuaFunction(L, 3);
            arg1 = () =>
            {
                func.Call();
            };
        }

        obj.addButtonNormalClick(arg0, arg1);
        return(0);
    }