예제 #1
0
 static int FuncGetMetaIndexer(IntPtr L)
 {
     try
     {
         Lua.DoStringInternal(
             L,
             "return function(be, script)\n" +
             "  return function(t, key)\n" +
             "    local val = script[key]\n" +
             "    return val or (type(val) == 'nil' and be[key])\n" +
             "  end\n" +
             "end", 1, "LuaBehaviour_MetaIndexer");
         return(1);
     }
     catch (Exception e)
     {
         Config.LogError("create FuncGetMetaIndexer error");
         Config.LogError(e.Message);
         return(0);
     }
 }