Exemplo n.º 1
0
 static int stringDelegate(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         LuaFunction arg0 = ToLua.CheckLuaFunction(L, 1);
         YlyDelegateUtil.StringDelegate o = YlyDelegateUtil.stringDelegate(arg0);
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Exemplo n.º 2
0
    static int _CreateYlyDelegateUtil(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 0)
            {
                YlyDelegateUtil obj = new YlyDelegateUtil();
                ToLua.PushObject(L, obj);
                return(1);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to ctor method: YlyDelegateUtil.New"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }