static int ReadBuffer(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         Framework.LuaBuffer        obj = (Framework.LuaBuffer)ToLua.CheckObject <Framework.LuaBuffer>(L, 1);
         LuaInterface.LuaByteBuffer o   = obj.ReadBuffer();
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Esempio n. 2
0
    static int ReadBuffer(IntPtr L)
    {
#if UNITY_EDITOR
        ToluaProfiler.AddCallRecord("Framework.LuaBuffer.ReadBuffer");
#endif
        try
        {
            ToLua.CheckArgsCount(L, 1);
            Framework.LuaBuffer        obj = (Framework.LuaBuffer)ToLua.CheckObject <Framework.LuaBuffer>(L, 1);
            LuaInterface.LuaByteBuffer o   = obj.ReadBuffer();
            ToLua.Push(L, o);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }